<?xml version="1.0" encoding="UTF-8"?>
<response><data><post><id>158</id><slug>headless-vs-headed-browsers-part-8-158</slug><title>Headless vs headed browsers, part 8</title><excerpt>Part 8 looks at what changes when the same technique has to run every day in production. Running a browser without a window is faster and works on servers, but some problems are much easier to…</excerpt><seriesName>Headless vs headed browsers</seriesName><seriesPart>8</seriesPart><sections><item><heading>Introduction</heading><paragraphs><item>Part 8 looks at what changes when the same technique has to run every day in production. Running a browser without a window is faster and works on servers, but some problems are much easier to understand when you can watch the browser do its work.</item></paragraphs></item><item><heading>A practical approach</heading><paragraphs><item>Time zones matter more than they seem. Store timestamps in UTC and convert only when displaying them.</item><item>Store raw responses alongside parsed output while you are developing. When a parser breaks, you can replay the saved HTML instead of hitting the site again.</item><item>Pagination comes in several shapes: numbered pages, next links, offsets and opaque cursors. Each has trade-offs, and a robust scraper should detect the end of the result set rather than assuming a fixed number of pages.</item></paragraphs></item><item><heading>Going further</heading><paragraphs><item>Selectors are the most fragile part of any scraper. Prefer stable attributes such as data-testid or semantic structure over generated class names, which can change on every deploy.</item><item>Always identify your client honestly with a descriptive User-Agent, and keep your request rate modest. A crawler that behaves like a considerate visitor is far less likely to cause problems for the site operator.</item></paragraphs></item><item><heading>Key takeaway</heading><paragraphs><item>Develop headed with slow motion turned on, run headless in CI, and capture screenshots or traces on failure so headless runs are still debuggable.</item></paragraphs></item></sections><authorId>8</authorId><authorName>Hannah Novak</authorName><authorSlug>hannah-novak</authorSlug><category>Browser Automation</category><tags><item>playwright</item><item>selenium</item><item>json</item></tags><publishedAt>2026-01-27T00:00:00.000Z</publishedAt><wordCount>211</wordCount><readingTimeMinutes>2</readingTimeMinutes></post></data></response>
