How to Capture a Full-Page Screenshot of an Infinitely Scrolling Page with ScreenshotMachine
ScreenshotMachine can capture a long finite page with `dimension=1366xfull`. For an endless feed, define a stopping point: the API guide does not document automatic scrolling.
Short answer: ScreenshotMachine documents full-page capture for a long finite page with the dimension parameter set to a width followed by xfull, such as 1366xfull. Its public API guide does not document automatically scrolling an infinite feed to load more entries. A longer delay gives the page more time to render, but it is not a documented way to trigger feed loading.
That distinction matters: a finite document has a final height; an infinite feed does not. Decide which items or stopping point you need, then capture the content available to the capture request. The examples below show a full-height request and how to save its image response.
1. Decide what “full page” means for an infinite feed
For a normal article or other long document, full height means capturing from the top to the document’s end. For an infinite feed, there may be no end: new entries can load only when the page receives scroll events, and “everything” has no stable meaning.
ScreenshotMachine’s API guide documents a full-height dimension, but does not explain that its capture engine scrolls the page or repeatedly triggers feed loading. Do not assume that one xfull request will include entries that had not loaded when capture began. Choose a practical endpoint first, such as the first 30 posts, a specific date, or the content already loaded when the capture starts. ScreenshotMachine’s API guide is the source for the documented settings described below.
2. Capture a long finite page with ScreenshotMachine
Use your customer key and the target URL. Set dimension to a width and full height. Pick a device rendering and image format. The vendor’s documented full-page example uses 1024xfull; this example uses a 1366-pixel width.
cURL
curl -G "https://api.screenshotmachine.com" \
--data-urlencode "key=YOUR_CUSTOMER_KEY" \
--data-urlencode "url=https://example.com/article" \
--data-urlencode "dimension=1366xfull" \
--data-urlencode "device=desktop" \
--data-urlencode "format=png" \
--data-urlencode "delay=2000" \
--data-urlencode "cacheLimit=0" \
--output screenshot.png
Replace YOUR_CUSTOMER_KEY with your key and the sample URL with the page you are authorized to capture. The API returns an image; cURL writes the response bytes to the named file.
Python
import requests
params = {
"key": "YOUR_CUSTOMER_KEY",
"url": "https://example.com/article",
"dimension": "1366xfull",
"device": "desktop",
"format": "png",
"delay": 2000,
"cacheLimit": 0,
}
response = requests.get(
"https://api.screenshotmachine.com",
params=params,
timeout=90,
)
response.raise_for_status()
with open("screenshot.png", "wb") as image_file:
image_file.write(response.content)
Node.js
const params = new URLSearchParams({
key: 'YOUR_CUSTOMER_KEY',
url: 'https://example.com/article',
dimension: '1366xfull',
device: 'desktop',
format: 'png',
delay: '2000',
cacheLimit: '0',
});
const response = await fetch(
`https://api.screenshotmachine.com?${params}`
);
if (!response.ok) {
throw new Error(`ScreenshotMachine returned HTTP ${response.status}`);
}
const image = Buffer.from(await response.arrayBuffer());
await import('node:fs/promises').then(fs => fs.writeFile('screenshot.png', image));
Run the Node.js example in an environment with global fetch and Node’s Buffer (for example, a current Node.js release). Keep the customer key on the server; do not embed it in public browser code.
3. Choose settings for the page and output
| Setting | What it controls | When to adjust it |
|---|---|---|
dimension |
Output width and height in WIDTHxHEIGHT form; full is accepted for height. Documented width range: 100–1920; numeric height: 100–9999. |
Use 1366xfull or another suitable width for a long finite page. A full-height setting does not establish how an endless feed is traversed. |
device |
Rendering profile: desktop, phone, or tablet. |
Choose the layout you need. The guide’s examples include desktop at 1024×768, phone at 480×800, and tablet at 800×1280. |
format |
Image format: JPG, PNG, or GIF. JPG is the documented default. | Set the format explicitly when downstream code expects a particular file type. Match the output filename extension. |
delay |
Wait before capture. Documented values are 0 and 200 ms increments through 10000 ms; default is 200 ms. | The guide suggests considering 2000 ms or more for some long pages with images or animation. Waiting can allow rendering to finish; it does not document feed scrolling. |
cacheLimit |
Maximum accepted age for a cached screenshot; values range from 0 to 14 days, including fractional intervals. | Set 0 to request a fresh screenshot instead of using a cached image. |
zoom |
Page zoom from 10% to 400%; default is 100%. | Change it if the desired capture needs a different scale. Check how it affects the visible layout before relying on it. |
The guide also documents click to trigger a CSS-selected element, hide to hide selected elements, cookies to supply cookies, accept-language and user-agent to set request context, selector to capture one DOM element, and crop to crop an image. These controls can prepare or narrow a capture; the documentation does not say they cause repeated infinite-feed loading.
4. If you need entries loaded by scrolling
- Set a bounded goal. Decide how many entries, which date range, or which known item should mark the end. An endless feed has no inherent final screenshot height.
- Check whether the target content is present before capture. If the site loads entries only after scroll events, a longer delay alone does not prove those entries will load.
- Try the documented full-height request for the content available to capture. Use
dimension=WIDTHxfulland a suitable device. Compare the result with the intended stopping point. - If entries are missing, use a capture method that explicitly scrolls and loads the feed before taking the image. The ScreenshotMachine guide consulted for this article does not provide a guaranteed infinite-scroll procedure, so its API settings cannot be presented as one.
- Keep the scope manageable. A very long image can be unwieldy to open, transfer, or process. If one image is not essential, capture bounded sections or individual items instead.
5. Troubleshoot missing or incorrect captures
| Symptom | Likely cause | What to do |
|---|---|---|
| Screenshot stops before the bottom of a long article. | The requested dimensions or page rendering did not produce the intended full-height result. | Check that dimension uses xfull, verify the requested width, and retry with enough rendering delay for the page’s images or animation. |
| Later feed entries are absent. | The entries may not have loaded before capture; the API guide does not document automatic scrolling to trigger them. | Define a stop point and use a method that explicitly scrolls the page to load the needed entries. Do not treat a larger delay as a feed traversal control. |
| Images or animations are incomplete. | The page may need more rendering time. | Increase delay in documented 200 ms increments, up to 10000 ms. The guide suggests considering 2000 ms or more for some long pages. |
| Old content appears after the page changed. | A cached screenshot may be acceptable under the configured cache limit. | Use cacheLimit=0 when you need a fresh capture. |
| Output cannot be opened as the expected format. | The requested format and saved file extension may not match, or the response may not be a successful image. | Set format explicitly, use the corresponding extension, and check the HTTP response before saving bytes in application code. |
| Layout differs from the intended viewport. | The chosen device profile, width, or zoom changes the rendered layout. | Choose desktop, phone, or tablet deliberately; adjust the dimension or documented zoom setting for the target layout. |
6. Performance, reliability, and cost considerations
Increasing delay adds waiting time to each request. Use only as much as the page needs, and remember that delay is for rendering time, not a guarantee that an infinite feed will load a chosen number of entries. A full-height result can also become large as page content grows; pick a useful width and a bounded capture scope.
For repeat captures, decide whether freshness matters. A nonzero cacheLimit permits a cached image within the accepted age; cacheLimit=0 requests a fresh image. The reviewed documentation does not establish a price, latency, maximum infinite-feed depth, or reliability guarantee, so check ScreenshotMachine’s current service terms for those details rather than assuming them.
7. Or skip the browser setup
If the goal is a clean screenshot without managing capture-browser behavior yourself, ScreenshotNeo is a website screenshot API and MCP server. One GET request takes a URL and returns PNG, JPEG, WebP, or PDF. Its clean-capture flow accepts cookie or consent banners like a visitor and removes 60+ known consent platforms, newsletter popups, and chat widgets; each of those steps can be turned off. Bot checks, blank pages, timeouts, failed loads, and cache hits are not billed, and response headers report the page verdict and billing status. AI agents can use its MCP server tools, including take_screenshot, get_page_info, and capture_pdf. It does not make an infinite feed have a natural endpoint: specify the content or stopping point your task needs.
See the ScreenshotNeo API documentation for parameters and options. This runnable cURL request captures a page as WebP:
curl -G "https://api.screenshotneo.com/v1/shot" \
-d access_key=YOUR_API_KEY \
--data-urlencode url=https://stripe.com \
-o shot.webp
Python:
import requests
r = requests.get(
"https://api.screenshotneo.com/v1/shot",
params={"access_key": "YOUR_API_KEY", "url": "https://stripe.com"},
timeout=90,
)
open("shot.webp", "wb").write(r.content)
Node.js:
const q = new URLSearchParams({ access_key: 'YOUR_API_KEY', url: 'https://stripe.com' });
const res = await fetch(`https://api.screenshotneo.com/v1/shot?${q}`);
ScreenshotNeo supports full-page capture with lazy images loaded, CSS-selector element capture, device presets and custom viewports, custom CSS and JavaScript, click and wait controls, request blocking, custom headers and cookies, caching with a chosen TTL, async jobs with signed webhooks, bulk capture of up to 100 URLs per call, and more. Plans include 1,000 screenshots per month free with no card; paid plans start at $5 for 3,000 shots. Sign up for 1,000 free screenshots a month, with no card required.
8. FAQ
Does 1366xfull mean unlimited page height?
It requests full height for the page as captured. It does not define an unlimited feed traversal or a stopping point for content that has not loaded.
Will setting a 10-second delay load more feed items?
The documented delay is a wait before capture. The guide does not describe it as a scroll trigger or infinite-feed loader.
Can I capture just one card in a feed?
The guide documents selector for capturing a single DOM element. It does not guarantee that an element not yet loaded into the page can be selected.
Which format should I choose?
ScreenshotMachine documents JPG, PNG, and GIF, with JPG as the default. Choose explicitly when your next tool expects a particular image format.


