Quick wins for a faster PC:
Clear out junk files and repair common Windows errorsFree Scan →Fix the driver behind crashes, sound loss and screen glitchesFind Drivers →There is no single pixel size that fits every mobile website background. Size the image for the CSS element that displays it: measure that element’s rendered width and height, account for the crop from background-size: cover, and provide enough source pixels for the device-pixel ratio (DPR) you support. Use a separate mobile image when the composition needs a different crop or the smaller asset meaningfully reduces downloads.
How to choose a mobile background image size
Start with the background’s container, not a list of phone resolutions. A phone does not have one fixed “website background size”: the page may have side margins, the hero may have a fixed or content-driven height, and the visible box changes with the layout. The same image can serve different screens if it fits the box and its composition survives the crop.
- Measure the rendered box. Find the element’s CSS-pixel width and height at the narrowest viewport you support. Include its actual layout constraints, not just the full viewport width.
- Check the image and box aspect ratios. Divide each width by its height. The closer these ratios are, the less of the image
coverneeds to crop. - Account for target DPR. A device with DPR 2 can use about two source pixels for each CSS pixel in each dimension. As a starting point, multiply the rendered dimensions by the highest DPR you choose to support; do not assume that every visitor needs the largest possible asset.
- Check the crop at real sizes. If the image uses
cover, test what remains visible at narrow and wide viewport shapes, including the placement of text and subjects.
For an image whose aspect ratio matches the container, the basic source-pixel target is approximately the container’s CSS width and height multiplied by the target DPR. When the ratios differ, cover scales the image until the box is filled and crops the excess. That crop affects which composition is visible; it does not mean that choosing a larger file automatically fixes a poor crop. Prefer a crop-safe image, or provide an asset composed for the target layout.
A practical sizing example
Suppose a mobile hero renders at 390 × 260 CSS pixels and you want a crisp candidate for DPR 2. A same-ratio source around 780 × 520 pixels is a reasonable starting point. This is an example, not a universal mobile-image specification: the right choice still depends on the actual hero dimensions, crop, image detail and supported devices. If the hero is taller, narrower or partly obscured by text, recalculate and inspect that layout rather than reusing the example dimensions.
Recommended Free Tools
#1 Best Overall
- YOUR CONTENT, SUPER SMOOTH: The ultra-clear 6.7" FHD+ Super AMOLED display of Galaxy A17 5G helps bring your content to life, whether you're scrolling through recipes or video chatting with loved ones.¹
- LIVE FAST. CHARGE FASTER: Focus more on the moment and less on your battery percentage with Galaxy A17 5G. Super Fast Charging powers up your battery so you can get back to life sooner.²
- MEMORIES MADE PICTURE PERFECT: Capture every angle in stunning clarity, from wide family photos to close-ups of friends, with the triple-lens camera on Galaxy A17 5G.
- NEED MORE STORAGE? WE HAVE YOU COVERED: With an improved 2TB of expandable storage, Galaxy A17 5G makes it easy to keep cherished photos, videos and important files readily accessible whenever you need them.³
- BUILT TO LAST: With an improved IP54 rating, Galaxy A17 5G is even more durable than before.⁴ It’s built to resist splashes and dust and comes with a stronger yet slimmer Gorilla Glass Victus front and Glass Fiber Reinforced Polymer back.
Understand how CSS background sizing changes the result
cover: fill the box, accept a crop
background-size: cover scales an image until the entire positioning area is covered. If the image and box have different aspect ratios, some of the image falls outside the visible area. Set background-position deliberately; the default centered crop may cut off a face, product or other important detail on a narrow screen.
contain: show the whole image
background-size: contain preserves the whole image, but it may leave unused space in the box. Use it when showing the entire graphic matters more than covering every part of the element. If gaps are unacceptable, choose a suitable background color or a composition with a closer aspect ratio rather than expecting contain to fill the box.
Position the focal point, then verify it
Use values such as center, left center, or a percentage to control which part of the image stays in view. The best position depends on the subject and the space reserved for text. Inspect the crop at the actual breakpoints: a focal point that looks good on one narrow screen can shift out of view when the box’s height or width changes.
Rank #2
- TYPE IT IN. TRANSFORM IT FAST: Enhance any shot in seconds on your smartphone by using Photo Assist¹ with Galaxy AI.² Add objects, restore details, or apply new styles by simply typing or tapping
- MAKE IT. EDIT IT. SHARE IT: Turn everyday moments into something personal with creative tools built right into your mobile whether it’s a special contact photo, custom wallpaper, an invitation or more³
- FAST. POWERFUL. AI-READY: Power through your day with AI-accelerated performance from our fastest, smoothest and most powerful Galaxy processor yet, built to keep up with everything you do
- IMMENSELY IMMERSIVE: No matter where you are or what you’re watching, your favorite videos and more come to life with the vibrant display on Galaxy S26
- FIT EVERYONE IN THE SHOT: Group selfies are easier on your Samsung phone with a wider front camera⁴ that captures more of the scene, so no one gets left out of the moment
Choose one image, density alternatives, or a mobile-specific crop
There are two different reasons to supply alternatives. Density alternatives provide more pixels for the same composition. Art direction swaps in a different composition or crop. Use the approach that solves the real problem; a high-density version of the desktop image does not fix a subject positioned outside the mobile crop.
Use media queries for a different mobile composition
Choose a separate asset when the mobile layout needs a tighter crop, a different focal point, or a simpler image. The following breakpoint is illustrative, not a standard definition of “mobile.” Choose the point where your layout or composition changes.
.hero {
background-image: url("/images/hero-mobile.webp");
background-size: cover;
background-position: center;
}
@media (min-width: 48rem) {
.hero {
background-image: url("/images/hero-wide.webp");
}
}
In this example the mobile file is the default, and the wider image is selected at 48rem and above. If your design’s changeover occurs elsewhere, adjust the media query to match it. A web.dev example published in 2020 reported a mobile background asset 67% smaller than its desktop counterpart; that is a result from that example, not a promised saving for other sites. The benefit for your page depends on the actual files and how they are delivered.
Rank #3
- YOUR CONTENT, SUPER SMOOTH: The ultra-clear 6.7" FHD+ Super AMOLED display of Galaxy A17 5G helps bring your content to life, whether you're scrolling through recipes or video chatting with loved ones.¹
- LIVE FAST. CHARGE FASTER: Focus more on the moment and less on your battery percentage with Galaxy A17 5G. Super Fast Charging powers up your battery so you can get back to life sooner.²
- MEMORIES MADE PICTURE PERFECT: Capture every angle in stunning clarity, from wide family photos to close-ups of friends, with the triple-lens camera on Galaxy A17 5G.
- NEED MORE STORAGE? WE HAVE YOU COVERED: With an improved 2TB of expandable storage, Galaxy A17 5G makes it easy to keep cherished photos, videos and important files readily accessible whenever you need them.³
- BUILT TO LAST: With an improved IP54 rating, Galaxy A17 5G is even more durable than before.⁴ It’s built to resist splashes and dust and comes with a stronger yet slimmer Gorilla Glass Victus front and Glass Fiber Reinforced Polymer back.
Use image-set() for resolution alternatives
When the composition stays the same but you have multiple density versions, CSS image-set() lets the browser select among them. Keep a plain declaration as a fallback when it is appropriate for your browser targets, and check current compatibility data for the syntax and any format options you use.
.hero {
background-image: url("/images/hero-1x.jpg");
background-image: image-set(
url("/images/hero-1x.jpg") 1x,
url("/images/hero-2x.jpg") 2x
);
background-size: cover;
background-position: center;
}
Density switching and art direction are not interchangeable: use a media query when the mobile image should show different content or framing, and density candidates when the framing remains suitable but sharper source pixels are available.
Crashes, No Sound, or Screen Glitches?
Random freezes, missing sound and display glitches usually trace back to one bad driver. Find and replace yours safely.Free scan · under a minuteWindows Errors? Fix Them Before They Spread
Repair common Windows errors and clear accumulated junk for a smoother, more stable PC - no reinstall needed.Free scan · no reinstallUse a CSS background only for decorative imagery
A background is suitable when the image is visual styling rather than information the reader needs. For a meaningful image, use an HTML <img> or <picture> element with appropriate alternative text and responsive source candidates. CSS backgrounds are not a replacement for text alternatives, and assistive technology does not get special information about the image merely because it appears behind content.
Rank #4
- Blazing-fast Qualcomm performance. Get the speed you need for great entertainment with a Snapdragon 680 processor and 4GB**** of RAM.
- Fluid display + immersive stereo sound. Bring your entertainment to life with an ultrawide 6.5" 90Hz* HD+ display plus stereo speakers, Dolby Atmos, and Hi-Res Audio**.
- 50MP*** Quad Pixel camera. Capture sharper, more vibrant photos day or night with 4x the light sensitivity.
- 64GB**** built-in storage. Get plenty of room for photos, movies, songs, and apps—and add up to 1TB more with a microSD card*****.
- Unbelievable battery life. Work and play nonstop with a long-lasting 5000mAh battery.*****
For content images, srcset can list candidate files and sizes can describe the expected display slot when using width descriptors. Use <picture> when you need media-based art direction or format alternatives, with an <img> fallback. This also makes the image’s semantic role explicit in the document rather than hiding it in presentation.
Protect loading performance, especially for a hero
Image dimensions and delivery strategy both matter. A large source file can cost unnecessary bytes on a small screen, while an undersized file can look soft on a high-density display. Compare the actual assets at their intended rendered sizes and avoid sending a desktop-sized download to mobile when a smaller suitable asset can be selected instead.
- Consider whether a hero can be an image element. A CSS background may be a page’s Largest Contentful Paint (LCP) candidate, but it is not discovered by the browser’s preload scanner in the same way as an image in the document. If the hero is the likely LCP element, evaluate whether an
<img>better fits its role. - If it must remain a background, assess responsive preloading. A responsive preload may help the browser discover the right viewport candidate earlier. Make sure it matches the image that CSS will use; preloading the wrong candidate can waste a request and bytes.
- Avoid excessive preloads. Preloading many assets competes for early network attention. Reserve it for resources whose early discovery matters.
- Review the chosen browser targets. Compatibility details can change. Check current browser support for the exact
image-set()form and formats you intend to ship rather than relying on an old support caveat.
Test the image in the layout, not just in an editor
Before shipping, inspect the rendered page at the viewport widths where the layout changes and on at least one high-DPR target. Browser developer tools can emulate viewport dimensions and device scale factors; also check real target browsers when their rendering or support matters. The useful question is whether the background remains sharp enough, keeps its subject visible, and loads the intended asset—not whether its filename says “mobile.”
Best Value
- YOUR CONTENT, SUPER SMOOTH: The ultra-clear 6.7" FHD+ Super AMOLED display of Galaxy A17 5G helps bring your content to life, whether you're scrolling through recipes or video chatting with loved ones.¹
- LIVE FAST. CHARGE FASTER: Focus more on the moment and less on your battery percentage with Galaxy A17 5G. Super Fast Charging powers up your battery so you can get back to life sooner.²
- MEMORIES MADE PICTURE PERFECT: Capture every angle in stunning clarity, from wide family photos to close-ups of friends, with the triple-lens camera on Galaxy A17 5G.
- NEED MORE STORAGE? WE HAVE YOU COVERED: With an improved 2TB of expandable storage, Galaxy A17 5G makes it easy to keep cherished photos, videos and important files readily accessible whenever you need them.³
- BUILT TO LAST: With an improved IP54 rating, Galaxy A17 5G is even more durable than before.⁴ It’s built to resist splashes and dust and comes with a stronger yet slimmer Gorilla Glass Victus front and Glass Fiber Reinforced Polymer back.
- Check the container’s real rendered width and height, including changes caused by text wrapping or responsive layout.
- Inspect
covercrops at narrow and wide sizes, and confirm that the focal point does not collide with text or controls. - Use the browser’s network panel to confirm which image candidate was requested and how large the transferred resource is.
- Compare the mobile-specific asset with the wide one. Confirm that the mobile version is actually selected at the intended viewport and is not needlessly oversized.
- If the background is a likely LCP image, inspect loading behavior as well as appearance; a visually correct image can still be discovered later than intended.
Troubleshoot common sizing problems
The image looks blurry on a phone
Check the element’s CSS dimensions and the device scale factor, then verify that the selected source has enough pixels for that rendered area. Also inspect the network request: a media query may be selecting an unexpectedly small file, or a density alternative may not be supported in the form used. Increasing image dimensions without checking the actual selected asset can leave the issue unchanged.
The subject is cut off on mobile
This is usually a composition or positioning issue rather than a shortage of pixels. Adjust background-position if the subject can stay visible in the existing asset. If the crop still fails at the mobile aspect ratio, create a mobile-specific composition and switch it with a media query.
The background leaves a gap or overflows its section
Confirm the element’s dimensions and the selected sizing mode. contain preserves the full image and can leave uncovered space; cover fills the area but crops. If the hero height is content-driven, the background box may also be shorter than expected. Fix the layout or choose the sizing mode that matches the design rather than applying arbitrary image dimensions.
The desktop image still downloads on mobile
Check the CSS cascade, media-query condition and computed background-image at the mobile viewport. Verify the actual network request rather than assuming the smaller asset was selected. If the mobile rule is overridden or the breakpoint does not match the layout change, correct that condition.
The hero appears late despite being correctly sized
Check whether it is a CSS background and whether it is the likely LCP element. Backgrounds may be discovered later than HTML images. Consider an image element if it is meaningful content, or assess a responsive preload if it must remain decorative background imagery. Do not preload every image as a workaround.
Or skip the browser setup
You can use ScreenshotNeo to capture a page while checking how a background renders. It is a website screenshot API and MCP server from Yorker Media. The example below captures a page screenshot; use a page where the relevant responsive layout is already available, then inspect the result. See the ScreenshotNeo documentation for API parameters.
Quick Recap
curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://freedom251.com -o shot.webp
ScreenshotNeo accepts cookie or consent banners like a visitor and removes 60+ known consent platforms, newsletter popups and chat widgets before capture; each of those steps can be turned off. Bot checks and CAPTCHAs, blank pages, timeouts, failed loads and cache hits cost nothing, and response headers identify the page verdict and billing status. Its MCP server gives AI agents tools for screenshots, page information and PDF capture. The free plan includes 1,000 screenshots a month with no card; paid plans start at $5 for 3,000.
Sign up for ScreenshotNeo’s free plan.
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

