DriversRecommendedOutdated drivers can make a good PC feel brokenScan driver issues before chasing fixes manually.Scan NowOctober DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsClean PCRecommendedOne scan can reveal what keeps slowing WindowsLook for cleanup and repair opportunities.Run Scan×
Skip to content
World desk5 min

Fix Playwright Screenshots That Include Scrollbars in the Wrong Place

A Playwright full-page screenshot captures the document, not every nested scroller. Identify what scrolls, then choose a viewport, full-page, or element screenshot accordingly.
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

First identify what is scrolling. page.screenshot() captures the current viewport; page.screenshot({ fullPage: true }) captures the full scrollable document as a tall image. It does not expand nested elements such as an overflow: auto panel. For a panel scrollbar, capture the panel or scroll it to the intended position; for a document scrollbar, use a viewport screenshot if you need to show the page as a user sees it.

Why a scrollbar appears missing or misplaced

“Wrong place” can mean several different things: the document scrollbar is absent from a full-page image, a nested panel is cropped, a fixed or sticky element looks unusual in a tall image, or CSS limits the page to the viewport height. These symptoms do not share one fix. Start by checking the screenshot mode and which element owns scrolling.

Playwright’s screenshot guide describes full-page capture as capturing the full scrollable page. It is not a series of ordinary viewport screenshots stitched together in a way that preserves the viewport scrollbar in the final tall image.

Choose the capture that matches the result you need

Goal Capture Tradeoff
Show the page as it appears in a browser window, including its current scrollbar state await page.screenshot({ path: 'view.png' }); Preserves viewport geometry, but content outside the viewport is not included.
Capture the whole document for an archive or comparison await page.screenshot({ path: 'full.png', fullPage: true }); Produces a tall document image; it does not expand nested scroll areas and may not show a scrollbar as a viewport capture does.
Capture content inside a scrolling panel await page.locator('.scroll-panel').screenshot({ path: 'panel.png' }); Targets the element. Check that its scroll position and dimensions match what you intend to show.

Diagnose and fix the scrolling element

1. Confirm whether you want a viewport or full-page image

For the visible browser view, omit fullPage. For the document’s full scrollable height, set fullPage: true. The two modes have different geometry, so scrollbar appearance can differ even when the page itself has not changed.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

2. Find the element that actually scrolls

Inspect document.scrollingElement and check for nested containers with fixed heights and overflow: auto or overflow: scroll. If the content scrolls inside a panel, document-level full-page capture will not expand it. Target the panel with locator.screenshot(), or scroll the panel to the desired position before taking a viewport screenshot.

#1 Best Overall
Sale
Philips 24 Inch Computer Monitor FHD 100Hz VA VESA Flicker-Free, 241V8LB
  • CRISP CLARITY: This 23.8″ Philips V line monitor delivers crisp Full HD 1920x1080 visuals. Enjoy movies, shows and videos with remarkable detail
  • INCREDIBLE CONTRAST: The VA panel produces brighter whites and deeper blacks. You get true-to-life images and more gradients with 16.7 million colors
  • THE PERFECT VIEW: The 178/178 degree extra wide viewing angle prevents the shifting of colors when viewed from an offset angle, so you always get consistent colors
  • WORK SEAMLESSLY: This sleek monitor is virtually bezel-free on three sides, so the screen looks even bigger for the viewer. This minimalistic design also allows for seamless multi-monitor setups that enhance your workflow and boost productivity
  • A BETTER READING EXPERIENCE: For busy office workers, EasyRead mode provides a more paper-like experience for when viewing lengthy documents
const panel = page.locator('.scroll-panel');
await panel.evaluate(element => { element.scrollTop = 300; });
await page.screenshot({ path: 'panel-view.png' });

That example captures the page viewport after moving the panel. To capture the element itself instead, use await panel.screenshot({ path: 'panel.png' });. Verify the output for your layout: an element screenshot and a viewport screenshot answer different questions.

3. Check height and overflow CSS

A fixed-height wrapper, overflow rule, or viewport-relative height such as 100vh can make the page behave differently from what you expect in a tall capture. A taller viewport can be a useful diagnostic experiment, but it changes the layout and is not automatically representative of the target device or browser window.

Rank #2
Philips 22 Inch Computer Monitor FHD 100Hz VA VESA Flicker-Free, 221V8LB
  • CRISP CLARITY: This 22 inch class (21.5″ viewable) Philips V line monitor delivers crisp Full HD 1920x1080 visuals. Enjoy movies, shows and videos with remarkable detail
  • 100HZ FAST REFRESH RATE: 100Hz brings your favorite movies and video games to life. Stream, binge, and play effortlessly
  • SMOOTH ACTION WITH ADAPTIVE-SYNC: Adaptive-Sync technology ensures fluid action sequences and rapid response time. Every frame will be rendered smoothly with crystal clarity and without stutter
  • INCREDIBLE CONTRAST: The VA panel produces brighter whites and deeper blacks. You get true-to-life images and more gradients with 16.7 million colors
  • THE PERFECT VIEW: The 178/178 degree extra wide viewing angle prevents the shifting of colors when viewed from an offset angle, so you always get consistent colors

In a Playwright issue about content that did not extend below the fold, collaborator Kyle Kang explained: “Playwright does not change the page layout, so if the content you would like to see on the screenshot does not appear below the fold, there is not much we can do.” The practical implication is to inspect the page’s CSS and layout assumptions rather than expecting full-page mode to rewrite them.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

4. Set the intended viewport before navigation

Responsive CSS can change the page’s layout when the viewport changes. The Page API documentation recommends setting viewport size before navigation because many sites do not expect phones to change size; changing viewport size also resets the screen size. Create the browser context with the intended viewport and screen dimensions, or set the viewport before goto.

Rank #3
Dell 24 Monitor - SE2426H - 23.8-inch FHD (1920x1080) 144Hz 1ms Display, in-Plane Switching (IPS) Technology, AMD FreeSync™, TÜV 3-Star 2X HDMI, Tilt
  • Clear visuals. Fluid motion: A 144Hz refresh rate and 1ms MPRT deliver smooth, tear‑free motion across work, gaming, and streaming for clearer, more fluid viewing.
  • Eye comfort: TÜV Rheinland 3‑star* certification reduces harmful blue light while preserving stunning color quality without compromise. *TÜV Rheinland 3-star eye comfort certification.
  • Wide viewing angle: Get consistent views across a wide 178° /178° viewing angle.
  • In-Plane Switching (IPS): See excellent color accuracy and consistency across wide viewing angles with In-plane Switching (IPS) technology.
  • Ultra-thin bezels: Maximize your viewing experience with thin bezels.
const context = await browser.newContext({
  viewport: { width: 1280, height: 800 },
  screen: { width: 1280, height: 800 }
});
const page = await context.newPage();
await page.goto('https://example.com');
await page.screenshot({ path: 'view.png' });

Replace the dimensions with the viewport you are testing. Do not increase them merely to make a scrollbar appear if the real requirement is to reproduce a particular user’s viewport.

Keep visual screenshot tests comparable

Playwright’s visual comparison assertions support fullPage. Playwright waits for two consecutive screenshots to match before comparing the last capture with the expectation. For useful visual-regression results, keep the screenshot mode, viewport, browser, and page state stable between the baseline and the comparison.

Rank #4
Sale
Samsung 27" Essential S3 (S36GD) Series FHD 1800R Curved Computer Monitor
  • CURVED FOR ENHANCED ENGAGEMENT: An immersive viewing experience with a curved monitor that wraps more closely around your field of vision; It creates a wider view, enhancing depth perception and minimizing peripheral distraction
  • SMOOTH PERFORMANCE FOR SEAMLESS CONTENT: Stay in the action when playing games, watching videos, or working on creative projects; The 100Hz refresh rate reduces lag and motion blur so you don't miss a thing in fast-paced moments¹
  • MORE GAMING POWER: Gain the edge with optimizable game settings; Color and image contrast can be adjusted to see scenes more vividly and spot enemies hiding in the dark; Game Mode adjusts any game to fill the screen so you can view every detail²
  • KEEP IT EASY ON THE EYES: Care for your eyes and stay comfortable, even during long sessions; Advanced eye comfort technology certified by TÜV reduces eye strain by minimizing blue light and reducing irritating screen flicker²
  • INCREASED VERSATILITY: Connect to more; Plug devices straight into your monitor for increased flexibility, making your computing environment even more convenient

Troubleshoot reports of a missing document scrollbar

Reports about omitted body scrollbars exist, but they describe particular setups rather than a universal regression. One report concerned Playwright 1.50.1 on Windows 11; another concerned Playwright 1.42.0 with .NET 8 on Windows and Chrome. These reports show that the symptom has occurred in specific configurations, not that every current Playwright and browser combination behaves the same way. See the 2025 issue and the 2024 issue.

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
  • Scrollbar missing only with fullPage: true: try a viewport capture if the goal is to show the browser-window view. Full-page mode creates a tall document image, not a viewport-preserving image.
  • Panel content cut off: confirm the panel, not the document, owns scrolling. Capture the panel or set its scroll position before capturing the viewport.
  • Content does not extend below the fold: inspect fixed heights, 100vh, and overflow rules. Test a larger viewport only as a diagnostic, since it can change responsive layout.
  • Visual test differs from its baseline: check that both captures use the same viewport, browser, screenshot mode, and page state.
  • Cause remains unclear: reduce the page to a minimal example and record the exact screenshot call, Playwright version, browser, operating system, and relevant CSS before attributing the issue to Playwright.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Or skip the browser setup

For a screenshot from a URL without setting up a Playwright browser, ScreenshotNeo provides a single-request screenshot API. Its website screenshot API returns a PNG, JPEG, WebP, or PDF; the options and response details are in the API documentation.

Best Value
Sale
Sceptre New 22-Inch Gaming Monitor, FHD 1080p, Up to 144Hz, HDMI, DisplayPort, Built-in Speakers, Machine Black (E225W-FW144 Series, 2026)
  • 【INTEGRATED SPEAKERS】Whether you're at work or in the midst of an intense gaming session, our built-in speakers provide rich and seamless audio, all while keeping your desk clutter-free.
  • 【EASY ON THE EYES】 Protect your eyes and enhance your comfort with Blue-Light Shift technology. This feature reduces harmful blue light emissions from your screen, helping to alleviate eye strain during long hours of use and promoting healthier viewing habits.
  • 【WIDEN YOUR PERSPECTIVE】Our sleek minimal bezel design ensures undivided attention. The nearly bezel-free display seamlessly connects in a dual monitor arrangement, delivering an unobstructed view that lets you focus on more at once, completely distraction-free.
curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -o shot.webp

ScreenshotNeo removes known consent banners, newsletter popups, and chat widgets before capture, and those steps can be disabled. Bot checks, blank pages, timeouts, failed loads, and cache hits are not billed; the response identifies the page verdict and billing status in headers. Its MCP server offers take_screenshot, get_page_info, and capture_pdf for AI agents. The free plan includes 1,000 screenshots a month with no card; paid plans start at $5 for 3,000 screenshots.

Sign up for ScreenshotNeo’s free plan to get 1,000 screenshots a month without a card.

Frequently Asked Questions

Does fullPage: true expand a scrollable div?

No. It captures the document’s scrollable content, not the full contents of every nested scroll container.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

How can I reproduce a specific missing-scrollbar report?

Use the same screenshot mode and, as closely as possible, the reported Playwright version, browser, operating system, viewport, and page CSS. Historical issue reports do not establish behavior across all current setups.

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.

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More from the Wire

  1. World desk4 min
    How to Spot an AI Voice Scam Before Sending MoneyDon’t rely on how a caller sounds. Pause, call back through a known number, and verify the emergency with another trusted person before sending money.
  2. Mountain View desk4 min
    Google’s SynthID Detector: How to Check AI-Generated Images, Video and AudioGoogle’s SynthID Detector looks for an embedded watermark in supported images, video and audio. Here is what its results do—and do not—show.
  3. Shenzhen desk3 min
    HONOR Expands Beyond Smartphones With Humanoid Robot RevealHONOR said it unveiled its first humanoid robot at MWC 2026 and named shopping assistance, workplace inspections, and supportive companionship as intended uses. Later Robotics D1 claims and a reported…
Recommended PC Tool
Recommended PC Tool
Outdated Drivers Are Slowing You DownFree scan - exact matches
Windows Errors? Fix Them Before They SpreadFree repair scan

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.