Guides for screenshots, PDFs and browser jobs
Find the failure. Reproduce it. Fix it. Every guide starts from a symptom you can trigger on purpose, builds the smallest Puppeteer or Playwright version that works, and says exactly where that version breaks — before it shows you an API request.
The code on these pages is executed against fixtures on a schedule, and each guide publishes what it costs, which limits apply and which errors you should expect. When the DIY version is the right answer, the guide says so.
14 guides · dated verification · runnable recipes
PDF and report generation
Turning HTML or a live page into a document someone keeps: print CSS, pagination, fonts, and delivering reports on a schedule.
5 guides
Generate PDFs with headers, footers and print CSS
Backgrounds disappear, content overlaps the footer, position:fixed repeats unexpectedly, or page numbers render with the default tiny font.
Turn an authenticated dashboard into a PDF report
Correct paper size, correct margins, and a document showing a login form, an empty shell, or charts still in their loading state.
Invoice PDFs your application can reproduce
Totals drift by a decimal between the screen and the PDF, a currency symbol renders as a box, the layout that fit one page on your laptop spills onto two in production, or the amount is right and the thousands separator belongs to another locale.
Turning Markdown into a file that renders the same everywhere
The release notes that looked right in the app arrive with tables collapsed into runs of pipes, or as unstyled black-on-white text that nobody wants to read.
Delivering report PDFs without holding a request open
A 502 or 504 from your own gateway while the render actually succeeded; duplicated report emails after a retry; or a queue that drains fine at 10 reports and collapses at 1,000.
Screenshots and web capture
Capturing pages you do not control: lazy loading, full-page output, serverless browsers, SSRF and browser job queues.
9 guides
Full-page screenshots with Puppeteer — and where they break
The output has blank image slots below the first fold, a sticky header repeated through the image, or a blank/truncated tail on a very tall document.
Running Playwright screenshots in serverless functions
Intermittent 5xx responses around deploys and traffic spikes, with most of the request budget spent before page.goto() starts.
Why lazy-loaded content is missing from screenshots
The page height is correct but image boxes below the fold are blank, low-resolution placeholders remain, or later list rows never exist in the DOM.
Loading web fonts reliably in HTML-to-image jobs
Production images wrap one word earlier than local output, use a system font, or shift between otherwise identical captures.
PNG or JPEG when your application generates the image
Text picks up a halo of grey speckle at the edges of glyphs, or a 1200x630 card leaves the renderer as a multi-megabyte PNG that a CDN then serves on every page view.
Why a transparent background arrives white, and how to keep the alpha
A logo, badge or card exported for use over an unknown background arrives with a white rectangle around it, and the CSS inspector insists the background is transparent.
SSRF defense for screenshot APIs
A public hostname reaches loopback, cloud metadata, RFC1918, Kubernetes service DNS or a custom storage/webhook endpoint that the caller could not access directly.
Queue, retry and idempotency for browser jobs
Two workers render the same request, the loser overwrites success with failure, a webhook fires twice, or usage contains a charge with no successful request left to justify it.
Build vs buy a screenshot API: an editable calculator
A confident annual-savings number whose result changes completely when one hidden engineering-hours assumption is made visible.
Code on these pages is re-executed against fixtures on a schedule. When a run fails or falls outside the re-execution window, the page stops claiming it was verified.
Useful before persuasive
A guide has to answer the technical question before it mentions PageCapture — well enough that you could finish the job without us and decide that is the better trade.
- 01Reproduce
Start from an observable symptom.
- 02Build
Show the smallest DIY version.
- 03Draw the boundary
Say where DIY works and where it breaks.
- 04Verify
Run the published recipe against a fixture.
PageCapture Engineering writes these guides. Editorial ownership belongs to @thalesvinif, the project maintainer. Each article names its reviewer and verification date. Browser facts link to primary documentation; product limits link back to the public PageCapture contract.
The published request is normalized by the same contract as the API, generated snippets receive syntax checks, and the scheduled verification job executes them against controlled fixtures. The dated badge expires when that run falls outside the verification window.