# UK Food Hygiene Ratings: Restaurants & Takeaways (FSA) (`frenchdatalab/uk-food-hygiene-ratings`) Actor

UK restaurants, cafes, takeaways, pubs, hotels and food shops from the official Food Standards Agency register: name, address, postcode, hygiene rating (0-5), inspection date, scores and GPS. Filter by type, council, rating and date; new-inspection alerts.

- **URL**: https://apify.com/frenchdatalab/uk-food-hygiene-ratings.md
- **Developed by:** [French Data lab](https://apify.com/frenchdatalab) (community)
- **Categories:** Lead generation, Automation, Developer tools
- **Stats:** 1 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.00 / 1,000 establishments

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

## UK Food Hygiene Ratings: Restaurants, Takeaways & Shops (FSA)

Every **UK food business** in the official **Food Standards Agency** register (500,000+ restaurants, cafes, takeaways, pubs, hotels, mobile caterers, shops, manufacturers…) with **name, address, postcode, hygiene rating, inspection date, detailed scores and GPS coordinates**.

Filter by **business type, council, town or postcode, name, rating and inspection date**, or schedule it to receive **only new businesses and new inspections**.

### What can you do with it?

- 🎯 **B2B leads in hospitality**: *"every restaurant and takeaway in Manchester"* for food suppliers, delivery platforms, card terminals, cleaning or pest control companies.
- 🧯 **Hygiene-related services**: *"restaurants rated 0 to 2 in Westminster"* need training, deep cleaning, consulting.
- 🆕 **New openings**: weekly alerts of newly registered businesses (often awaiting inspection) and new ratings.
- 🗺️ **Market mapping**: count and locate food businesses by council and type (GPS included).

### Why this Actor?

| | This Actor | Typical FSA tools |
|---|---|---|
| Councils by name | ✅ "Westminster", "Leeds" | ⚠️ numeric ids |
| Rating and inspection-date filters | ✅ min / max rating, inspected since, new rating pending | ❌ |
| Clean data | ✅ postcodes recovered when typed inside the address, placeholder dates (1901-01-01) removed, numeric rating field | ⚠️ raw |
| Monitoring | ✅ only new businesses and new inspections | ❌ |
| Big extractions | ✅ 5,000 per request, all pages | ⚠️ |

### Input

| Field | Description | Example |
|---|---|---|
| `businessTypes` | Restaurant/cafe, takeaway, pub, hotel, mobile caterer, retailers, supermarkets… | `[1, 7844]` |
| `localAuthorities` | Council names | `["Westminster"]` |
| `address` | Town or postcode text | `"Brighton"` |
| `businessName` | Name contains | `"pizza"` |
| `minRating` / `maxRating` | 0 to 5 | `0`, `2` |
| `inspectedSince` | Inspection date | `"2026-06-01"` |
| `newRatingPendingOnly` | Recently inspected, new rating not published yet | `false` |
| `onlyNewInspectionsSinceLastRun` | Monitoring mode | `true` |
| `maxResults` | Maximum establishments | `5000` |

### Output

Real example (shortened):

```json
{
    "fhrsId": 1836353,
    "businessName": "60 Degrees Coffee",
    "businessType": "Restaurant/Cafe/Canteen",
    "address": "UNIT 10B 10 GREYCOAT PLACE, LONDON",
    "postcode": "SW1P 1SB",
    "localAuthority": "Westminster",
    "rating": "2",
    "ratingNumber": 2,
    "ratingDate": "2025-06-30",
    "scheme": "FHRS",
    "url": "https://ratings.food.gov.uk/business/1836353"
}
```

Other fields: `phone` (rarely published), `localAuthorityEmail`, `newRatingPending`, `hygieneScore`, `structuralScore`, `managementScore` (lower is better), `latitude`, `longitude`.

### Notes

- Scotland uses the Food Hygiene Information Scheme (`scheme: FHIS`, ratings "Pass" / "Improvement Required"): 0-5 filters apply to England, Wales and Northern Ireland.
- Ratings change after each inspection: always use the current rating or show `ratingDate`, as the FSA terms require.

### Pricing

Pay per establishment returned. Set a maximum cost per run and the Actor stops exactly there.

### Source & licence

Food hygiene rating data from the **Food Standards Agency**, licensed under the **Open Government Licence v3.0**. This Actor is independent and not endorsed by the FSA.

# Actor input Schema

## `businessTypes` (type: `array`):

Leave empty for all types.

## `localAuthorities` (type: `array`):

Council names, e.g. "Westminster", "Manchester", "Leeds", "Edinburgh" (partial names match all councils containing them).

## `address` (type: `string`):

Free text searched in the address, e.g. "Brighton" or "SW1A".

## `businessName` (type: `string`):

e.g. "pizza", "costa".

## `minRating` (type: `integer`):

England, Wales and Northern Ireland ratings (Scotland uses Pass / Improvement Required).

## `maxRating` (type: `integer`):

e.g. 2 for poorly rated establishments.

## `inspectedSince` (type: `string`):

YYYY-MM-DD

## `newRatingPendingOnly` (type: `boolean`):

Establishments inspected recently whose new rating is not published yet.

## `onlyNewInspectionsSinceLastRun` (type: `boolean`):

Monitoring: schedule the Actor (e.g. weekly) and receive only new businesses and new ratings.

## `maxResults` (type: `integer`):

Maximum number of establishments returned.

## Actor input object example

```json
{
  "businessTypes": [
    "1"
  ],
  "localAuthorities": [
    "Westminster"
  ],
  "newRatingPendingOnly": false,
  "onlyNewInspectionsSinceLastRun": false,
  "maxResults": 50
}
```

# Actor output Schema

## `establishments` (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 = {
    "businessTypes": [
        "1"
    ],
    "localAuthorities": [
        "Westminster"
    ],
    "maxResults": 50
};

// Run the Actor and wait for it to finish
const run = await client.actor("frenchdatalab/uk-food-hygiene-ratings").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 = {
    "businessTypes": ["1"],
    "localAuthorities": ["Westminster"],
    "maxResults": 50,
}

# Run the Actor and wait for it to finish
run = client.actor("frenchdatalab/uk-food-hygiene-ratings").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 '{
  "businessTypes": [
    "1"
  ],
  "localAuthorities": [
    "Westminster"
  ],
  "maxResults": 50
}' |
apify call frenchdatalab/uk-food-hygiene-ratings --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,frenchdatalab/uk-food-hygiene-ratings"
        }
    }
}
```

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/sKdig1aG7fiOY8WaQ/builds/oBdSo74lpfzt7p1ej/openapi.json
