---
title: Recipe: Scraper with retries · Agent Playground docs
description: Fetches a page from a flaky site, waits and retries when it's busy, then parses the table and saves it. What it does, when to use it, how to make it yours, and what a run costs.
url: https://www.quietrobot.ai/docs/playground/recipes/scraper-retries
---

# Recipe: Scraper with retries

Fetches a page from a flaky site, waits and retries when it's busy, then parses the table and saves it. What it does, when to use it, how to make it yours, and what a run costs.

Fetches a page from a website that's often busy, waits and tries again when it is, then reads the price table out of the page and saves it as a spreadsheet file.

| At a glance | |
|---|---|
| **Category** | Data |
| **Shape** | A retry loop with a pause |
| **Plan** | Free and up |
| **Needs a Claude key** | No |
| **Limits it comes with** | 5 loops, 240 seconds, $0.05 |

```flow
{"title": "Scraper with retries, as it is on the canvas.", "nodes": [["site", "run", "Start test site"], ["fetch", "code", "Fetch page"], ["pause", "wait", "Wait 3 s", "3 s"], ["parse", "code", "Parse table"], ["save", "run", "Save"]], "edges": [["site", "fetch"], ["fetch", "pause", "Failed"], ["pause", "fetch"], ["fetch", "parse", "Passed"], ["parse", "save"]]}
```

<figure class="shot">
  <img class="art-light" src="/docs/playground/recipes/scraper-retries-light.webp" alt="The Scraper with retries recipe in the builder after a run, with each step's result on the canvas and the run's steps listed on the right." width="1440" height="900" loading="lazy">
  <img class="art-dark" src="/docs/playground/recipes/scraper-retries-dark.webp" alt="" width="1440" height="900" loading="lazy">
  <figcaption>A real run of the recipe. The panel on the right lists every step with what it printed.</figcaption>
</figure>

## When to use it

* Collecting prices, stock levels, listings or schedules from a website that has no download button.
* Calling any service that sometimes answers "busy, try again".
* A daily schedule that saves a fresh copy of a page's data.

## Run it

1. Open **Agent Playground** in the dashboard and find **Scraper with retries** under **Start from a recipe**. In the builder, **Recipes** in the toolbar lists them too.
2. Choose **Use this recipe**. It becomes a flow of your own, so changing it never changes the recipe.
3. Choose **Simulate** to see the forecast, then **Run**.

**What you'll see:** **Fetch page** fails twice ("The site answered 503: will wait and try again"), **Wait 3 s** waits between tries, and the third try works. **Parse table** saves three prices to `prices.csv`, and **Save** shows the first row.

## Make it yours

1. Delete **Start test site**: it's a stand-in website that's busy on purpose.
2. Point **Fetch page** at the real page.
3. Change **Parse table** to read the table or fields you need from that page.
4. Set the flow's **Policy** to **Only these sites**, with just that website, so the flow can't reach anything else.
5. Raise **Wait** for sites that ask you to slow down, and keep **Loops** low so a site that's down for the day doesn't keep you trying. Then add a daily **Schedule** trigger.

> [!NOTE]
> Only collect data you're allowed to. Check the website's terms, and prefer an official download or API when there is one.

## What a run costs

These are the builder's own forecast for the recipe as it comes, with its limits, rounded. **Simulate** shows the same numbers for your version, and they change as you change the flow.

| | Typical | 1 in 10 runs | At most |
|---|---|---|---|
| **Sandbox time** | $0.0002 | $0.0003 | $0.0031 |
| **How long it takes** | 14 seconds | 27 seconds | 240 seconds |

A typical run uses $0.0002 of sandbox time, so about 5,500 runs cost $1, and every plan includes $5 of usage a month. **At most** is the most a run could cost with these limits: it stops at $0.05 or 240 seconds, whichever comes first.

## Related

* [Tutorial 3: Keep trying until it works](https://www.quietrobot.ai/docs/playground/tutorials/loops)
* [Tutorial 6: Run a flow on its own](https://www.quietrobot.ai/docs/playground/tutorials/triggers)
* [Data and evals recipes](https://www.quietrobot.ai/docs/playground/recipes/data-and-evals)
* [All recipes](https://www.quietrobot.ai/docs/playground/recipes)
