What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.
Some links on this page are affiliate links: if you buy through them we may earn a commission, at no extra cost to you.
PhantomJS can capture CSS background images: open the page, let the relevant background resource load, then call page.render(). PhantomJS enables image loading by default, but the page.open() callback is not a universal guarantee that a background applied or changed asynchronously is ready. Set the viewport before opening the page, verify the CSS rule and image URL, and wait for the condition that matters on your site before rendering.
Capture a page with its CSS background
PhantomJS renders web pages with its WebKit-based engine, so a screenshot can include CSS-styled HTML as well as images, SVG and Canvas. The basic capture call is page.render('capture.png'). The filename extension selects the output format by default; PNG is a suitable choice when preserving image detail matters. See the render API and the screen-capture guide.
Save this as capture.js and run it with the PhantomJS executable:
var page = require('webpage').create();
page.viewportSize = { width: 1280, height: 800 };
page.open('https://example.com/', function (status) {
if (status !== 'success') {
console.log('Unable to load the page.');
phantom.exit(1);
return;
}
// The page has opened. For backgrounds set asynchronously,
// wait for the site-specific condition before rendering.
page.render('capture.png');
phantom.exit();
});
Replace the example URL with the page you need. This baseline works when the page’s background rule and image are ready by the time the open callback runs. If a script applies the background later, use the more careful readiness approach below instead of assuming a fixed delay will always be sufficient.
#1 Best Overall
- 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
What PhantomJS loads by default
page.settings.loadImages defaults to true. If you change it, configure the setting before the first page.open() call; it is not a switch to flip after opening the page and expect the initial request to be reloaded. The page settings documentation also describes resourceTimeout and the onResourceTimeout callback for detecting timed-out requests.
Wait for the background your page actually uses
A CSS background is not necessarily represented by an ordinary <img> element. A site can set or replace background-image after initial page load, for example when application code runs or responsive styles are applied. The official documentation does not specify one wait duration that works for every site’s asynchronous assets, nor does it guarantee every dynamic background is ready at the open callback.
Rank #2
- 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
- Identify the target rule. Inspect the element that should have the background and determine which CSS selector and URL apply at the screenshot viewport. A background may belong to a parent, pseudo-element, or a different responsive rule than expected.
- Match the viewport. Set
page.viewportSizebeforepage.open(), using the dimensions relevant to the CSS breakpoint and layout you intend to capture. - Wait for a specific signal. If the page sets the background asynchronously, wait for the relevant class, computed style, application state, or resource completion. The signal should correspond to the background you need, not merely to a guessed number of milliseconds.
- Render after readiness. Call
page.render()only after the chosen condition is satisfied. If the condition never occurs, record a useful diagnostic and exit rather than silently saving a misleading capture.
The exact signal depends on the page. For a static page, the open callback may be enough; for a dynamic app, use a condition specific to the element and background. Avoid claiming that a generic delay proves an image is loaded: slow networks, script timing and lazy behavior can all change when the resource becomes available.
Set the viewport and capture region deliberately
viewportSize controls the browser viewport used to lay out the page. This affects responsive CSS, including media queries that change or remove a background. Set it before opening the URL. The screen-capture guide also documents clipRect, which selects a portion of the rendered page for capture; it does not cause a missing background resource to load.
Rank #3
- 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.
| Capture choice | What it controls | When it helps |
|---|---|---|
viewportSize |
Viewport width and height used for page layout and responsive styles | When the background or page layout changes at different screen widths |
clipRect |
The region of the rendered page included in the capture | When you need a particular area rather than the full rendered page |
| PNG or JPEG output | The image format; the render API selects by filename extension unless another format is specified | Choose PNG when retaining image detail is important; format choice will not fix an absent CSS resource |
These controls are described in the official capture guide and render API. Keep the file extension consistent with the output you expect, such as capture.png or capture.jpg.
Troubleshoot a missing background
The CSS rule does not apply at the capture size
Check the selector, cascade, media queries and computed style for the intended element at the configured viewport. Responsive CSS may point to another image or set background-image: none at a particular width. Set viewportSize before the initial open and use the dimensions at which the rule should apply.
Rank #4
- 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
The URL is wrong or the request did not succeed
Verify the URL in the active CSS rule and check whether the image request succeeds. A typo, unavailable file, inaccessible host or timed-out request cannot produce the intended pixels. PhantomJS settings document a resource timeout and an onResourceTimeout callback; use those to detect timed-out requests and report the failing resource where possible. A screenshot format change does not repair a failed image request.
The page changes the background after opening
Check whether client-side code inserts the class or style that supplies the background after the open callback. Wait for that page-specific state or resource before calling page.render(). The documentation confirms image loading is enabled by default, but does not promise that every dynamically assigned background has completed at a particular callback.
Best Value
- 【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.
The screenshot is the wrong size or crop
Compare the configured viewport to the intended responsive layout, then check whether clipRect excludes the area containing the background. A clip rectangle changes what is captured, not the page’s CSS or resource-loading result.
You expect modern browser behavior
PhantomJS’s project home page says development is suspended until further notice and identifies QtWebKit as its backend. The project page does not state a modern compatibility target. If a current site depends on browser features that this older rendering stack does not handle, the background may not behave as it does in a modern browser. See the PhantomJS project home page.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Or skip the browser setup
If your goal is to get a screenshot rather than maintain a PhantomJS script, ScreenshotNeo is a website screenshot API and MCP server. One GET request can return a PNG, JPEG, WebP or PDF. For a simple capture:
Quick wins for a faster PC:
Scan for outdated or missing drivers - takes under a minuteDriver Scan →Clear out junk files and repair common Windows errorsFree Scan →Fix the driver behind crashes, sound loss and screen glitchesFind Drivers →curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://example.com/ -o shot.webp
See the ScreenshotNeo API documentation for parameters and response details. Its capture options include viewport and device settings, full-page capture, custom CSS and JavaScript, and waiting for a selector, delay or network idle. For background-image cases, those options let you set the capture context and wait behavior, but you still need to choose a condition appropriate to the site.
- Cookie and consent banners, newsletter popups and chat widgets are removed before capture; each of those steps can be turned off.
- Bot checks or CAPTCHAs, blank pages, timeouts, failed loads and cache hits cost nothing; response headers identify the page verdict and whether the request was billed.
- An MCP server exposes
take_screenshot,get_page_infoandcapture_pdfto Claude, Cursor and other MCP clients. - The free plan includes 1,000 shots per month with no card; paid plans start at $5 for 3,000 shots. Every feature is on every plan.
To try a capture, sign up for 1,000 free 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.

