CSS content-visibility: auto can reduce the browser’s initial rendering work on long pages by letting it skip layout and painting for substantial offscreen sections until they become relevant. Pair it with contain-intrinsic-size to reserve space for those sections, then measure the result on your own page: the often-cited 7× gain came from a specific web.dev demonstration, not a general guarantee.
What content-visibility does—and what it does not do
The content-visibility property controls whether an element’s contents are rendered. With auto, the browser may skip rendering work—including layout and painting—for offscreen content, and perform that work when the content becomes relevant. This can help on pages with large amounts of content that a visitor does not initially see.
It does not remove markup from the DOM, reduce the page’s network transfer, or generally replace work to reduce JavaScript execution. Its benefit is specifically about rendering work. Use it on sizable, meaningful chunks such as independent article sections rather than indiscriminately applying it to every node.
How to apply it safely
Start with substantial offscreen sections
Apply content-visibility: auto to section-level elements whose contents are expensive to render and likely to start below the fold. Keep the chunks meaningful and independent. Code that calls DOM APIs and forces a skipped subtree to render can undermine the optimization, so review code that measures or manipulates those sections.
#1 Best Overall
Reserve plausible space
.article-section {
content-visibility: auto;
contain-intrinsic-size: auto 500px;
}
The 500px value is illustrative, not a recommended universal size. contain-intrinsic-size gives the browser a placeholder size while size containment is active. With auto 500px, the browser can use a remembered rendered size when available and the supplied fallback otherwise. Choose a fallback close to the section’s normal size, then check scroll position and layout as sections render. A poor estimate can make the page’s reserved space differ noticeably from the rendered content.
Understand skipped-state behavior
MDN’s containment guidance describes skipped contents as having layout, style, paint, and size containment: they are not painted and do not receive pointer events while skipped. The auto value can still allow content to be searched and focused, and the browser can make it relevant and render it. Do not confuse auto with hidden; they have different behavior.
Rank #2
- Used Book in Good Condition
Accessibility and application behavior
Content in an auto-contained offscreen section remains in the DOM and accessibility tree. This can preserve access to content, searching, and focus navigation. There is an important edge case: because styles for skipped content have not been rendered, descendants intended to be removed from the accessibility tree using display: none or visibility: hidden may still appear there before the section becomes relevant. If content must be absent from the accessibility tree, web.dev advises using aria-hidden="true". Use that only when it matches the intended semantics, and verify behavior with assistive technology.
For elements using auto, the contentvisibilityautostatechange event lets application code respond when the browser starts or stops skipping an element. For example, code that draws into a canvas can use the event to stop unnecessary drawing while the element is skipped and resume when rendering is needed.
Rank #3
- Used Book in Good Condition
Measure the gain on your page
web.dev reported a 7× rendering performance boost on initial load in its 2020 demonstration after applying content-visibility: auto to chunked content areas. That is a result for that demonstration—not a controlled universal estimate or a forecast for another site.
Your result depends on how much expensive rendering work is initially offscreen and whether application code forces the browser to render skipped content. Compare before and after on representative pages and devices. Check the initial rendering and interaction cost, how sections affect layout as they appear, and whether the behavior remains accessible and usable for your audience. Use browser diagnostics where available to investigate unexpected work or layout changes.
Rank #4
Browser support
MDN labels content-visibility Baseline Newly available since September 2024. A later web.dev announcement says it became available across all three major browser engines as of September 15, 2025. These milestones indicate broad availability in current engines, not guaranteed support on older browser versions or devices. Check the compatibility data against the browsers your audience actually uses before depending on the property.
Troubleshooting common problems
- Little or no performance improvement: The page may have little expensive offscreen rendering work, or code may be forcing skipped subtrees to render. Apply the property to substantial offscreen chunks, then inspect the page’s rendering behavior and relevant DOM-measuring code.
- Scroll position or spacing changes as content appears: The intrinsic-size fallback may not resemble the section’s normal size. Adjust the fallback using representative sections and recheck the page as content renders.
- Hidden descendants are exposed to assistive technology: Styles such as
display: noneorvisibility: hiddenmay not have taken effect for skipped content. Where the semantics require exclusion from the accessibility tree, consideraria-hidden="true"and verify with assistive technology. - Older browsers do not behave as expected: Broad current-engine availability does not ensure support on older clients. Check the browser compatibility table and test the versions and devices you support.
- Canvas or other application work continues while offscreen: Use
contentvisibilityautostatechangewhere appropriate to stop work while the browser skips the element and resume it when the element becomes relevant.
Or skip the browser setup
If you need a screenshot of a page rather than a CSS optimization, ScreenshotNeo is a website screenshot API and MCP server. Its API can return a screenshot or PDF from one GET request; it does not implement or measure content-visibility performance.
The Tool Desk
Outbyte PC Repair FREEClear out junk files and repair common Windows errorsFree Scan →Outbyte Driver Updater FREEScan for outdated or missing drivers - takes under a minuteDriver Scan →Best Value
For example, with cURL (see the API documentation):
curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -o shot.webp
ScreenshotNeo accepts cookie and consent banners and removes more than 60 known consent platforms, newsletter popups, and chat widgets before capture; each step can be turned off. Bot checks and CAPTCHAs, blank pages, timeouts, failed loads, and cache hits cost nothing, with the page verdict and billing status included in response headers. An MCP server provides take_screenshot, get_page_info, and capture_pdf for AI agents and MCP clients. The Free plan includes 1,000 screenshots per month with no card; paid plans start at $5 for 3,000 shots.
Sign up for ScreenshotNeo’s free plan to get 1,000 screenshots a month with no card.
Quick Recap
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.




