arrow_back All posts
August 26, 2026 · 4 min read ·

Build a Web Scraper Without Writing the Code Yourself

Describe in plain language what to collect and let an agent write the scraper. Plus robots.txt, throttling, and why selectors always eventually break.

You want the data — prices from a supplier's catalog, listings from a directory, your own site's pages audited — not a programming education. That used to mean hiring someone or wrestling with a scraping tutorial until the enthusiasm died. With an AI coding agent, the honest version is simpler: you describe what to collect in plain language, the agent writes the fetch-and-parse script, and you get rows out the other end in CSV. The part nobody emphasizes enough comes after it works once — because websites change, and scrapers break. Here's how to do both halves right.

Say what you want, not how to get it

The prompt that works describes outcomes, not implementation. Which pages, which fields on each page — name, price, date, link — and what output format you want. "Go to this listing page, follow the pagination, and give me every item's title, price, and URL as a CSV" is a complete spec; you don't need to know what an HTML parser is. The agent picks the library, writes the fetch logic, and handles the parsing details you'd have spent a weekend getting wrong.

Connect the Claude or Codex you already pay for — the rest runs on workers that cost a fraction.

Download meshcode →

What the agent actually writes, briefly

Under the hood the script fetches each page, parses the HTML, and pulls out the fields using selectors — addressable patterns for pieces of the page. Worth knowing honestly: a plain-language spec can miss things the agent has to discover, like pagination that loads more items on scroll, pages behind a login, or content rendered by JavaScript rather than present in the raw HTML. If the first run comes back with zero rows, that's usually why — say so, and the agent will adjust the approach rather than you debugging blind.

Into CSV or a spreadsheet

Insist on CSV output even if your real destination is something else. It opens directly in Excel or Google Sheets, diffs cleanly, and gives you a checkpoint before anything fancier happens downstream. From there the data can flow wherever you'd take any spreadsheet — into recurring automated reports, or further, if you decide to turn the spreadsheet into an app instead of emailing files around. For smaller repetitive chores inside the sheet itself, we've also covered automating spreadsheet tasks with AI.

Respect robots.txt and the site's terms

This isn't a legal disclaimer bolted on for form. robots.txt is the file where a site says what crawlers may and may not access — check it, and tell your agent to honor it. Some sites' terms of service forbid scraping outright regardless of what robots.txt allows; others offer an official API precisely so you don't have to scrape. When an API exists, use it — it's more stable anyway, because it doesn't depend on page markup. And keep personal data out of your scrapes unless you've thought through why you're collecting it.

Throttle your requests

Firing hundreds of rapid requests at a server is rude at best and gets your IP blocked at worst — sometimes taking unrelated tools on the same network down with it. Ask for a delay between requests, run big jobs off-peak, and have the script retry politely with backoff when a request fails rather than hammering. A scrape that takes an hour is fine. A scrape that takes four minutes and gets you banned is not.

Expect selectors to break — plan for maintenance

Here's the part one-shot thinking gets wrong: the site redesigns its product page, the selectors stop matching, and your scraper starts returning empty columns — or worse, silently stale ones. This isn't a flaw in how it was built; it's the nature of pointing software at markup someone else controls. Treat the scraper as a maintained tool, not a finished artifact: schedule re-runs, add a check that alerts you when row counts drop to zero or fields come back empty, and expect to ask the agent for a selector repair every so often. Ten minutes of maintenance per redesign beats discovering months of missing data later.

The meshcode angle

A scraper is exactly the kind of self-contained chore agents are good at, and meshcode gives it a good home: a native desktop app for macOS and Windows where each pane runs its own agent session against the same project — one pane writing the scraper while another builds the spreadsheet side. Drive your existing Claude Code or Codex CLI subscription, or start on meshcode's own metered models, billed pay-as-you-go with no monthly fee.

👉 Download meshcode — Mac, Windows

web scraper without codingweb scrapingai agent automationcsv exportrobots txtno code scraping