There is no single “best image size for a website.” A hero image, a blog illustration, a product card and a tiny thumbnail do not occupy the same amount of space, so they should not all be delivered at the same dimensions.
The useful way to size website images is to start with the largest rendered slot, then add enough pixel density for sharper displays, create a small set of responsive candidates, and compress those delivery files. Current 2026 guidance from Shopify follows the same pattern: different image roles use different dimensions and aspect ratios rather than one site-wide number.
Short version: size by component, not by website. Measure the actual CSS width, preserve or intentionally crop the aspect ratio, provide responsive source widths, and avoid sending a giant original to every screen.
A practical starting-point table
The numbers below are starting points, not universal requirements. Your design system and container widths should override generic recommendations.
| Image role | Useful starting range | Typical ratio | What to verify |
|---|---|---|---|
| Full-width hero | 1280–2000+ px wide | 16:9, 3:2 or custom | Actual viewport/container width, DPR, crop |
| Wide banner | 1200–1800 px wide | 3:1, 2.5:1 or custom | Text-safe area and mobile crop |
| Blog/article image | 800–1600 px wide | 3:2, 4:3, 16:9 | Maximum content-column width |
| Content illustration | 600–1400 px wide | Source-dependent | Text/detail legibility |
| Card image | 400–1000 px wide | 1:1, 4:3, 3:2 | Grid column width and DPR |
| Thumbnail | 150–600 px wide | Often 1:1 or 4:3 | Rendered size, not source library size |
Shopify’s 2026 website-image guide lists examples such as 1280×720 for a hero, 1200×800 for blog imagery and 1200×400 for banners, while explicitly noting that responsive designs may require adjustment. Treat those as useful reference points, not fixed standards.
The correct dimension starts with the CSS slot
Suppose an article image never renders wider than 900 CSS pixels. A 5000-pixel camera original is not inherently better for that slot. It transfers and decodes far more data than the layout can use.
A better approach is to provide several candidates—perhaps 480w, 960w and 1800w—and let the browser select among them according to layout and display density. MDN’s responsive-image documentation explains how srcset and sizes give the browser that information.
Hero images
Heroes are often the largest visible image on a page and can become the Largest Contentful Paint element, so both dimensions and delivery behavior matter.
For many layouts, a source around 1280–1920 pixels wide is a sensible starting point, but a full-bleed 4K-style marketing canvas may need a larger candidate. The right answer depends on whether the hero fills the viewport, whether content is constrained inside a max-width container, and how the image is cropped.
Do not assume the desktop crop will work on a phone. A separate mobile composition can outperform a single extremely wide source clipped into a narrow portrait viewport. See Best Hero Image Size for Desktop and Mobile.
Website banners
Banners are usually much shallower than heroes, so aspect ratio is the important constraint. A 1200×400 image is 3:1. If your actual banner is closer to 4:1, preserving a 3:1 source with cover will crop more heavily than expected.
Measure the component ratio first. Then create the crop, then choose pixel widths that correspond to real display sizes.
Blog and editorial images
Blog imagery rarely needs the same source width as a full-bleed hero if the article column is constrained. A 1200-pixel-wide source is often comfortable for a column around 600 CSS pixels on a 2× display, while a wider editorial layout may justify 1600 or 1800 pixels.
Do not make every image 2000 pixels simply because the theme allows it. Check the maximum content width in the actual template.
Content screenshots and diagrams
Screenshots are different from photographs because text and UI details can become unreadable after aggressive downscaling. The “best” size is the smallest delivery width that still preserves the information the reader needs.
If a screenshot is meant to teach a tiny interface detail, consider cropping to the relevant region rather than shrinking an entire desktop screen into a narrow article column. That is often more useful than preserving every part of the source.
Cards and thumbnails
Repeated grid imagery is a classic place to waste bytes. If a card renders at 320 CSS pixels wide, a 2400-pixel source is excessive. A small responsive set can serve standard- and high-density screens without bloating every grid item.
Uniform card ratios also make layout more predictable. Use the aspect ratio guide to decide whether the card should crop with cover or display the entire asset with contain.
How device pixel ratio changes the answer
On a higher-density display, the browser can use more physical pixels to render the same CSS-pixel slot. MDN notes that browsers can multiply the expected source size by device pixel ratio when selecting a srcset candidate.
This is why a 600 CSS-pixel image can legitimately use a source near 1200 pixels wide on some screens. But it does not mean every visitor should always download the 1200-pixel candidate.
Use responsive images instead of one oversized file
A responsive source set lets the browser choose. For example:
<img
src="article-960.webp"
srcset="
article-480.webp 480w,
article-960.webp 960w,
article-1800.webp 1800w"
sizes="(max-width: 700px) 100vw, 900px"
width="1800"
height="1200"
alt="...">
The exact values should match your layout. The point is that the 1800-pixel file is available without being mandatory for a small screen.
Dimensions are not the same as file size
A 1600×900 image can be 120 KB or 2 MB depending on image content, format and compression. Pixel dimensions are one part of the performance budget; encoding is another.
After right-sizing the image, use the existing Image Compression Guide and Best Image Format for the Web to choose the delivery encoding.
Should every image be under a specific KB limit?
No single byte limit works for every image role. A prominent photographic hero can justify a larger budget than a 100-pixel icon. Instead, budget by visual importance and performance impact.
The more useful rule is: do not transfer pixels or bytes the user cannot benefit from. A right-sized 1600-pixel hero may reasonably be larger than a 400-pixel card, but both should still be compressed appropriately.
Width and height attributes
Even when images are responsive, include intrinsic width and height so the browser can derive the aspect ratio and reserve space before the resource loads. MDN and web.dev both document this as a way to reduce layout shifts.
Worked example: a responsive marketing site
Imagine a site with a 1440-pixel max-width desktop layout, a 900-pixel article column and three-column cards that render at roughly 380 pixels each.
- Hero: perhaps 800w, 1440w and 2200w candidates, with a mobile art-directed crop if needed.
- Article: perhaps 480w, 960w and 1800w.
- Cards: perhaps 320w, 640w and 900w.
Those values are derived from component widths, not from one global “website image size.”
Website image-sizing checklist
- Measure the maximum rendered width of each component.
- Choose the component’s aspect ratio intentionally.
- Create a small number of useful responsive source widths.
- Account for high-density displays without forcing the largest file on everyone.
- Supply intrinsic width and height.
- Compress the delivery candidates.
- Check the browser’s actual network selection.
- Revisit sizes when the layout changes.
Resize before you upload
Use the browser image tool to resize oversized source photography before it enters your CMS. Choose dimensions from the component you are preparing for, then select the format and quality in the same workflow.
Frequently asked questions
Is 1920 pixels wide the best size for every website image?
No. It can be useful for wide heroes and large media, but it is unnecessarily large for many content columns, cards and thumbnails.
What is a good blog image size?
Start from the article column. If the image renders around 600–900 CSS pixels wide, candidates around 600–1800 pixels can cover common standard- and high-density scenarios without forcing one size on everyone.
Should mobile images be smaller?
Usually, yes in delivered pixel width, but mobile can also need a different crop. Responsive source selection and art direction solve different parts of the problem.
Do image dimensions affect SEO?
Dimensions affect performance and presentation, which matter to users. Google also needs crawlable, useful image implementations. Avoid treating one pixel size as an SEO ranking trick; use dimensions that serve the page well.
Sources and further reading
- Shopify: Website Image Size Guidelines for 2026
- MDN: Responsive images
- web.dev: Serve images with correct dimensions
- MDN: <img> element
Image Resizing & Dimensions
A practical series on choosing, resizing, cropping, and delivering the right image dimensions for the web.
- Image Resizing: The Complete Guide to Dimensions, Resolution and Aspect Ratio
- How to Resize an Image Without Losing Visible Quality
- Crop vs Resize: What’s the Difference?
- Aspect Ratio Explained: How to Resize Images Without Stretching Them
- Best Image Size for a Website: Hero, Banner, Blog and Content Images
- Best Hero Image Size for Desktop and Mobile
- Pixels vs Resolution vs File Size: What Actually Matters on the Web?
- Does DPI Matter for Web Images? The 72 DPI Myth Explained