# Good Food Scraper (`thescrapelab/good-food-scraper`) Actor

Search Good Food recipes by name keywords or scrape recipe and collection URLs. Get ingredients, instructions, yields, times and labelled nutrition. Export JSON or CSV.

- **URL**: https://apify.com/thescrapelab/good-food-scraper.md
- **Developed by:** [Inus Grobler](https://apify.com/thescrapelab) (community)
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

$0.60 / 1,000 recipe delivereds

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Good Food Scraper

Search public Good Food recipes by name keywords, or collect recipes from individual links and recipe collections. Get original ingredients and method steps, recipe yields, preparation and cooking times, and nutrition with the site's labels and units. Results are available as JSON, CSV, Excel and other Apify dataset exports.

### What you can do

- Import recipes you have permission to use into a cooking or meal-planning application.
- Collect recipe URLs and original ingredient lists for food research.
- Export consistent recipe records from several collections without duplicate recipe URLs.

Use it to import recipes you are entitled to use into recipe applications, maintain recipe URL collections, or export source data for food research. Premium and gated content is skipped. No account, external API key or AI service is required.

### Quick start

Open the Input tab, enter a search phrase or add Good Food recipe/collection URLs, choose the maximum number of recipes, and select Start. A nonempty search phrase takes precedence over URLs, so you can leave the prefilled example URL in place. Open the dataset after the run to view or export results.

Search example:

```json
{
  "searchQuery": "chicken pasta",
  "maxItems": 10
}
```

URL example:

```json
{
  "startUrls": [
    {"url": "https://www.bbcgoodfood.com/recipes/easy-pancakes"}
  ],
  "maxItems": 10
}
```

For a collection, use a URL such as `https://www.bbcgoodfood.com/recipes/collection/pancake-recipes`. Collection pages are followed until the global recipe limit is reached or their available results are exhausted. Overlapping recipe URLs are deduplicated. The limit counts exported recipes, rather than page requests or premium cards.

With the search phrase empty, the unchanged default recipe URL returns one recipe; the maximum does not add unrelated recipes.

### Recipe keyword search

Search uses Good Food's public recipe sitemaps to find matching recipe URLs, then verifies every result against its current recipe title. All meaningful search words must match; word order, common joining words, case, accents and simple plurals are handled. For example, `chicken pasta` can match a title containing both words, and `pancake` can match `pancakes`.

This is recipe-name keyword search. It does not call the website's blocked search pages or internal search API, reproduce Good Food's relevance ranking, search ingredient-only mentions, infer dietary suitability or expand synonyms. Recipe URL keywords are used for discovery, so a matching title whose URL uses different words can be missed. Shorter matching URLs are tried first, with an alphabetical tie-break. Newly published recipes can be missing from the public index.

Search reads the public recipe index before collecting results, which can add startup time. A phrase with no accessible matches fails clearly with an empty dataset; it does not substitute the default recipe. Try fewer or different dish-name keywords if results are empty. The run summary includes the search phrase, index coverage and skipped title mismatches.

### Inputs

| Input | Required | Meaning |
| --- | --- | --- |
| `searchQuery` | No | Optional recipe-name keywords, for example `chicken pasta`. Takes precedence over URLs when nonempty. Up to 200 characters and 12 meaningful words. |
| `startUrls` | No | Public Good Food recipe or collection URLs, used when the phrase is empty. The default is Easy pancakes. |
| `maxItems` | No | Maximum unique recipes across all supplied URLs, from 1 to 1,000. Default: 10. The run can return fewer if sources are exhausted or a spending limit is reached. |

Use either a search phrase or URLs; existing URL-only API inputs keep working. No cookies, login, proxy configuration or external API subscription is required.

### Pricing

**$0.60 per 1,000 delivered recipes ($0.0006 each), with no startup fee or monthly rental.** Standard Actor run usage is included; there is no additional platform-usage surcharge for a standard run.

| Delivered recipes | Recipe charge |
| --- | --- |
| 1 | $0.0006 |
| 10 | $0.006 |
| 100 | $0.06 |
| 1,000 | $0.60 |

Only validated recipes written to the default dataset count as results. Duplicate URLs, skipped premium content and failed requests do not produce billable recipe rows. The default input points to one recipe and normally costs $0.0006. Check the Actor's Pricing tab for the current terms before starting.

Set a positive maximum run charge in Console or the API to control spending. Apify requires a starting limit that covers at least one recipe: use **$0.0006 or more**. Do not pass a literal zero, because the platform can treat it as an unset limit. A positive limit below $0.0006 is rejected by Apify before a run starts.

If the remaining allowance cannot cover another recipe, collection stops with `SPENDING_LIMIT` in the run summary and preserves the delivered output. A resumed run whose allowance is already spent makes no further source requests. Recipe limits and spending limits both apply.

### Output

Each dataset row represents one recipe. Ingredient and instruction arrays preserve source order. The following excerpt shows selected fields from the default recipe; complete rows also include the original ingredient and instruction arrays, author, image URL, other nutrient values and the collection timestamp.

```json
{
  "url": "https://www.bbcgoodfood.com/recipes/easy-pancakes",
  "title": "Easy pancakes",
  "yieldText": "Makes 12",
  "servings": null,
  "prepMinutes": 10,
  "cookMinutes": 20,
  "totalMinutes": 30,
  "timeNote": "Plus optional standing",
  "nutritionBasis": "per pancake",
  "caloriesKcal": 61,
  "fibreG": 0,
  "saltG": 0.1
}
```

`yieldText` retains the original yield. A count of items produced is not automatically a serving count. `nutritionBasis` preserves qualifications such as per pancake or per serving without syrup. Nutrition values apply to that basis and are not rescaled. `saltG` is salt in grams; it is not sodium. Missing optional source values are null, and actual zero values remain zero.

| Fields | Meaning |
| --- | --- |
| `url`, `title`, `author` | Original recipe URL, title and author when available. The URL is the unique recipe key. |
| `ingredients`, `instructions` | Arrays of original ingredient lines and method steps, in source order. |
| `yieldText`, `servings` | Original yield wording and a numeric serving count only when explicitly stated. |
| `prepMinutes`, `cookMinutes`, `totalMinutes`, `timeNote` | Durations in minutes and extra qualifications such as chilling or standing. |
| `nutritionBasis` | The source's basis for the nutrition values, such as per pancake. |
| `caloriesKcal` | Energy in kcal, for that nutrition basis. |
| `fatG`, `saturatedFatG`, `carbohydratesG`, `sugarsG`, `fibreG`, `proteinG`, `saltG` | Source nutrient values in grams, for that nutrition basis. |
| `imageUrl`, `scrapedAt` | Source image link and retrieval time in UTC. Image files are not downloaded. |

JSON preserves the arrays. CSV exports expand arrays into indexed columns such as `ingredients/0` and `instructions/0`, so the number of CSV columns depends on recipe length.

The run summary links to coverage, excluded content, source errors and the stopping reason. Target errors do not appear as recipe rows. A run that cannot collect any valid recipe fails with an explanatory summary. Runs with valid output and failed targets report partial coverage in that summary.

### Python API example

```python
import os
from datetime import timedelta
from decimal import Decimal
from apify_client import ApifyClient

client = ApifyClient(os.environ["APIFY_TOKEN"])
run = client.actor("thescrapelab/good-food-scraper").call(
    run_input={
        "startUrls": [{"url": "https://www.bbcgoodfood.com/recipes/easy-pancakes"}],
        "maxItems": 10,
    },
    memory_mbytes=512,
    run_timeout=timedelta(seconds=120),
    max_total_charge_usd=Decimal("0.01"),
)
if run is None:
    raise RuntimeError("The Actor did not return a completed run.")
for recipe in client.dataset(run.default_dataset_id).iterate_items():
    print(recipe["title"], recipe["url"])
```

The Actor must be accessible to your Apify account. The example's spending limit is an upper bound, not a minimum fee. No paid proxy is enabled.

### Coverage and troubleshooting

- URL inputs support only HTTPS `bbcgoodfood.com/recipes/...` and `/recipes/collection/...`. The optional phrase searches public recipe names; internal APIs, videos and premium content are unsupported.
- Content walls are checked even when the URL looks like a free recipe. Collection item counts can include premium recipes and videos, so the exported recipe count can be lower.
- A collection is exhausted when it has no next page. The Actor also stops repeated pages and applies bounded requests and retries. It does not promise the entire Good Food catalogue or a fixed number of accessible recipes.
- Larger collections can take longer because source response times vary. Increase the timeout in Console run options when requesting larger volumes. Existing output is retained if a run is interrupted.
- For larger searches, select 1 GB memory in Console run options and allow at least 15 minutes; increase the timeout if the source is slow. Small/default URL runs can use the default 512 MB. Supply enough accessible, distinct source recipes. The input ceiling does not guarantee that every phrase or collection contains 1,000 free matches, or that a large job will finish within a fixed time.
- Ingredients and methods are checked against the displayed source lists. Unexpected layouts are reported rather than exported as incomplete recipes. Nutrition fields are taken from the visible panel.
- For no results, check that the supplied pages exist and contain ungated recipes. For partial results, inspect the run summary for denied requests, source changes and excluded content. Retry temporary failures after the source recovers.
- Use collected content only within the rights and permissions applicable to your use. This unofficial Actor is not affiliated with Good Food or Immediate Media.

### Support

Open an issue in the Actor's Issues tab with the run ID, affected public URLs and the expected result. Do not include account credentials. Include the run summary when reporting partial results or spending-limit questions.

# Actor input Schema

## `searchQuery` (type: `string`):

Optional recipe-name keywords, for example chicken pasta or pancakes. Searches public recipe sitemaps and verifies recipe titles. All meaningful words must match. A phrase takes precedence over URLs, including the prefilled example. Ingredient-only matches and the website search ranking are unsupported.

## `startUrls` (type: `array`):

Optional Good Food recipe links or /recipes/collection/ links. Used when the search phrase is empty. Collections are paginated. Premium, account and internal API URLs are unsupported.

## `maxItems` (type: `integer`):

Maximum valid, unique recipes for the entire run. The run stops earlier when the supplied sources are exhausted.

## Actor input object example

```json
{
  "startUrls": [
    {
      "url": "https://www.bbcgoodfood.com/recipes/easy-pancakes"
    }
  ],
  "maxItems": 10
}
```

# Actor output Schema

## `recipes` (type: `string`):

No description

## `csv` (type: `string`):

No description

## `summary` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "startUrls": [
        {
            "url": "https://www.bbcgoodfood.com/recipes/easy-pancakes"
        }
    ],
    "maxItems": 10
};

// Run the Actor and wait for it to finish
const run = await client.actor("thescrapelab/good-food-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "startUrls": [{ "url": "https://www.bbcgoodfood.com/recipes/easy-pancakes" }],
    "maxItems": 10,
}

# Run the Actor and wait for it to finish
run = client.actor("thescrapelab/good-food-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "startUrls": [
    {
      "url": "https://www.bbcgoodfood.com/recipes/easy-pancakes"
    }
  ],
  "maxItems": 10
}' |
apify call thescrapelab/good-food-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,thescrapelab/good-food-scraper"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/wHwncJjzeY8lBf8Tp/builds/AdqIpkCYMKx8FH1aD/openapi.json
