Install puppeteer, launch its bundled browser, open the page you need, and save it with page.screenshot(). For a visible-screen capture, use the default settings; add fullPage: true for the full document. The steps below work for a college project in India as for any Node.js project—the exact submission requirements, such as image format and page dimensions, depend on your instructor.
Install Puppeteer and capture a page
Run these commands from your project folder. The standard puppeteer package downloads a compatible Chrome for Testing browser as part of its default setup.
As an Amazon Associate I earn from qualifying purchases.
npm install puppeteer
In a project configured for ES modules, save this as screenshot.js and run node screenshot.js:
import puppeteer from 'puppeteer';
const browser = await puppeteer.launch();
try {
const page = await browser.newPage();
await page.setViewport({ width: 1280, height: 800 });
await page.goto('https://example.com', { waitUntil: 'networkidle2' });
await page.screenshot({ path: 'screenshot.png' });
} finally {
await browser.close();
}
Replace the example URL with your project page, whether it is deployed or running locally. The output file is written relative to the directory from which you run the script. The viewport is set before navigation so the page renders at the chosen dimensions. The finally block closes the browser even if navigation or capture fails.
#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
This example uses networkidle2 as a navigation wait condition; it is not a guarantee that every site will become idle. If a page keeps making network requests, select a wait condition suitable for that page and, where necessary, wait for a specific element or a known delay before taking the screenshot. Puppeteer’s official getting-started guide documents the launch, page, navigation, viewport, and browser-close sequence: Puppeteer getting started.
Choose what the screenshot should show
Visible viewport
By default, page.screenshot() captures the current page view. This is usually the right choice when the assignment asks for a screenshot of what a user sees without scrolling.
Entire page
Set fullPage: true to capture the whole document, including content below the viewport:
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
await page.screenshot({ path: 'full-page.png', fullPage: true });
One element
For a specific component, find it with a CSS selector and call screenshot() on the resulting element handle. Puppeteer scrolls the element into view if needed; the call throws if that element has been removed from the DOM.
const element = await page.$('.project-card');
if (!element) {
throw new Error('Could not find .project-card');
}
await element.screenshot({ path: 'project-card.png' });
Change .project-card to a selector that identifies an element on your page. The selector must match an element after the page has loaded. See the ElementHandle screenshot API.
Clipped region, transparency, and image format
The screenshot API also supports clip for capturing a specified rectangular region and omitBackground for a transparent background. The quality option applies to image formats that support it; it does not apply to PNG. Puppeteer infers the image type from the filename extension, so use an extension such as .png, .jpeg, or .webp that matches the format your assignment requests. Check the screenshot options for the exact option shapes and supported behavior.
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.
Match the capture to your assignment
Before submitting, check the assignment brief and confirm the following details. There are no single India-wide college screenshot rules established here; requirements come from your instructor or institution.
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 →- Target page: Use the required URL, and verify whether your local development server must be running.
- Scope: Decide whether the brief wants the visible viewport, the entire page, or one component.
- Dimensions: Set the viewport width and height to the specified values; otherwise, choose dimensions that make the page legible.
- Format and path: Save the requested image type to the expected folder and use a matching filename extension.
- Rendered state: Make sure the relevant content, images, and UI state have appeared before capture.
A screenshot records the page’s rendered state at one moment. By itself, it does not demonstrate that every part of the application works.
Use the browser Puppeteer supports best
Puppeteer documents its bundled Chrome for Testing as the browser it works best with. Compatibility with arbitrary Chrome installations is not guaranteed. If your environment requires a separately installed browser, use puppeteer-core and provide an executablePath or channel in the launch options. See the launch reference before changing the browser configuration.
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
Troubleshoot common capture problems
The browser does not launch
If Puppeteer cannot find or start a browser, first confirm that you installed puppeteer rather than only puppeteer-core. The standard package includes its compatible browser download workflow. If you intentionally use puppeteer-core, configure the executable path or browser channel for the installed browser; an arbitrary Chrome version may not be compatible.
Navigation waits too long
A page that continuously polls, streams, or loads third-party resources may not satisfy a network-idle condition. Use a different navigation wait condition or wait for the specific content needed for the image instead of assuming all network activity will stop.
Recommended Free Tools
The element screenshot fails
Check that the selector matches an element on the page after navigation and that the page has not removed that element before capture. Element screenshots can scroll a found element into view, but they cannot capture an element that no longer exists.
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 saved image has the wrong scope or format
Use fullPage: true for the whole document; omit it for the current viewport. Verify the filename extension against the required image format, since Puppeteer uses that extension to infer the output type.
Or skip the browser setup
If you want a screenshot without installing or managing a browser in your project, ScreenshotNeo provides a website screenshot API and an MCP server for developers. One GET request can return an image or PDF. For example, this cURL request saves a WebP capture of a page:
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 setup and options. ScreenshotNeo removes known cookie/consent banners, newsletter popups, and chat widgets before capture; each step can be turned off. Bot checks or CAPTCHAs, blank pages, timeouts, failed loads, and cache hits are not billed, and response headers identify the page verdict and billing status. Its MCP server provides take_screenshot, get_page_info, and capture_pdf tools for AI agents. The free plan includes 1,000 screenshots per month with no card; paid plans start at $5 for 3,000 screenshots.
PC Slower Than It Used to Be?
A free scan shows the junk files, broken settings and background clutter dragging Windows down - then fixes them in one click.Free scan · Windows 10 & 11Crashes, 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 minuteSign up for ScreenshotNeo’s free plan to get 1,000 screenshots a month with no card.
Frequently Asked Questions
Does Puppeteer take a screenshot of the whole page by default?
No. The default captures the current viewport; set fullPage: true to capture the full document.
Can Puppeteer save a screenshot of just one HTML element?
Yes. Select the element and call screenshot() on its element handle. Puppeteer scrolls it into view when needed.
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.
The Tool Desk
Outbyte Driver Updater FREEScan for outdated or missing drivers - takes under a minuteDriver Scan →Outbyte PC Repair FREEClear out junk files and repair common Windows errorsFree Scan →




