# UK CQC Care Providers & Sub-Ratings Scraper (`kailouis_labs/uk-cqc-care-providers-sub-ratings-scraper`) Actor

Extract 57,000+ UK CQC care homes, clinics & providers from the official OGL directory with all 5 live sub-ratings (Safe, Effective, Caring, Responsive, Well-led), bed capacity, registered managers & warning notices. Filter directly for Inadequate or Requires improvement leads.

- **URL**: https://apify.com/kailouis_labs/uk-cqc-care-providers-sub-ratings-scraper.md
- **Developed by:** [Kailouis Labs](https://apify.com/kailouis_labs) (community)
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $6.00 / 1,000 cqc care provider records

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 CQC Care Providers Scraper

**Every CQC-registered care location in England — 57,000+ records — with the ratings and sub-ratings that the official CSV does not contain.**

The Care Quality Commission publishes a free, OGL-licensed directory of every registered location in England. It has names, addresses and phone numbers. It has **no ratings at all**, no inspection dates, no registered manager. So most UK care-sector lead lists are either stale spreadsheets built by hand, or they come from scrapers that hammer the CQC website one page at a time and cost the buyer a fortune.

This Actor does both halves properly: it starts from the **official bulk CSV** (one download, 18 MB, ~57k rows, always the newest monthly edition) and only then spends HTTP requests on the locations you actually asked for, to pull the rating intelligence from their public pages. Filters run **row by row inside the CSV stream, before any page is fetched**, and non-matching rows are dropped on the spot, so a targeted pull of 2,000 records costs about 2,000 page requests, not 57,000.

Built for UK healthcare B2B teams: care-home SaaS vendors, healthcare recruiters and staffing agencies, compliance and turnaround consultants, M\&A and market analysts, insurance and risk teams, and local-authority commissioning analysts.

***

### What you get

- **57,000+ live CQC locations** in England, from the official monthly CQC directory (OGL v3, commercial use permitted with attribution).
- **All five key-question sub-ratings** — Safe, Effective, Caring, Responsive, Well-led — plus the overall rating. These exist only on the location page, never in the CSV, and are the single field most competitor datasets are missing.
- **Rating status** that tells you the difference between *rated*, *partially rated*, *not yet rated* and *not rated by CQC because the service type is outside rating scope* — so a blank rating never gets mistaken for a bad one.
- **Inspection and report dates** (`latestReportDate`, `dateOfLatestCheck`, `latestReviewDate`).
- **Registered manager** name, **bed capacity** (from the location's registration conditions), specialisms / regulated activities, local authority, region, postcode, phone, website, provider ID and CQC deep link.
- **Trigger filtering** for demand-generation lists: keep only providers rated `Inadequate` or `Requires improvement`, optionally matching **any** sub-rating — i.e. "find me every care home in the South East that is Good overall but Inadequate on Safety".
- **Flat, export-ready JSON**: one row per location, no nested arrays. Drops straight into Excel, Google Sheets, HubSpot, Salesforce, Airtable or a CSV integration with no flattening step.
- **Polite by design**: plain HTTP + Cheerio (no headless browser, no proxy required), 6 concurrent requests by default, exponential backoff on 429/5xx, and a monthly CSV cache so repeat runs skip the download.

***

### Why this one instead of a generic CQC scraper

| | Generic directory dump | Page-by-page scrapers | **This Actor** |
|---|---|---|---|
| Coverage | 57k rows | Whatever finishes | 57k rows, always the newest CSV |
| Overall rating | ✗ | ✓ slow | ✓ |
| 5 sub-ratings | ✗ | Partial / missing | ✓ all five, verified labels |
| Filter before fetching | ✗ | ✗ | ✓ in the CSV stream, zero wasted requests |
| Cost for a 500-record filtered pull | free but useless | 500+ full page loads | 1 CSV + 500 polite page loads |
| "Only inadequate providers" one-click | ✗ | ✗ | ✓ |
| Flat export schema | ✗ | Often nested | ✓ 31 flat columns |

Standard CQC CSV exports and most competing Actors give you contact data with no rating intelligence, or ratings for a slice of the country that took hours to fetch. This Actor gives you the whole register, filtered down before it spends a single request.

***

### Input

Everything is optional. With no input at all you get 100 enriched records from the national CSV — a cheap, fast way to see the output shape.

| Field | Type | Default | What it does |
|---|---|---|---|
| `serviceTypes` | array | `[]` (all) | Case-insensitive partial match on CQC service type: `Residential homes`, `Nursing homes`, `Homecare agencies`, `Supported living`, `Dentist`, `Doctors/GPs`, `Clinic`, `Hospice`, `Hospital`, `Extra Care housing`. |
| `regions` | array | `[]` (all) | CQC regions: London, South East, South West, East of England, Midlands, North East and Yorkshire, North West. |
| `postcodePrefixes` | array | `[]` (all) | e.g. `["SW", "E1", "M1"]`. Spaces and case ignored. |
| `excludePostcodePrefixes` | array | `[]` | Trim areas out of a wider pull. |
| `localAuthorities` | array | `[]` | Exact local authority names, e.g. `Wandsworth`, `Kent`. |
| `providerName` | string | `""` | Partial match on provider (operator) or location name — track one group like `Barchester` or `HC-One`. |
| `includeSubRatings` | boolean | `true` | Fetch each filtered location's public CQC page for ratings, sub-ratings, dates, manager, bed capacity, specialisms. Turn off for a directory-only pull. |
| `filterByRating` | array | `[]` | e.g. `["Inadequate", "Requires improvement"]`. Applied to the overall rating, or to any sub-rating when `matchAnySubRating` is on. |
| `matchAnySubRating` | boolean | `false` | Match `filterByRating` against any of the five sub-ratings instead of the overall rating. |
| `maxItems` | integer | `100` | Safety cap for cheap test runs. `0` = unlimited. |
| `maxConcurrency` | integer | `6` | 1–8. Keep it low to stay welcome on cqc.org.uk. |
| `requestDelaySecs` | number | `0.2` | Pause between requests to the same domain. |
| `cacheDirectory` | boolean | `true` | Reuse the downloaded CSV for 24 h across runs. |
| `requestTimeoutSecs` | integer | `45` | Per-request timeout, 10–120. |
| `debugLog` | boolean | `false` | Verbose logging. |

#### Example: struggling care homes in South West London

```json
{
  "serviceTypes": ["Residential homes", "Nursing homes"],
  "postcodePrefixes": ["SW"],
  "includeSubRatings": true,
  "filterByRating": ["Inadequate", "Requires improvement"],
  "matchAnySubRating": true,
  "maxItems": 0
}
```

***

### Output

One flat object per location. This is a real record from a test run (`postcodePrefixes: ["SW"]`, `maxItems: 25`):

```json
{
  "locationId": "1-119125834",
  "providerId": "1-102643071",
  "locationName": "Anvil Close",
  "providerName": "MacIntyre Care",
  "serviceType": "Residential homes",
  "address": "21-24 Anvil Close, Streatham, London",
  "postcode": "SW16 6YA",
  "region": "London",
  "localAuthority": "Wandsworth",
  "phone": "02086774717",
  "website": "https://www.macintyrecharity.org",
  "registeredManager": "Miss Mandy Fisher",
  "bedCapacity": "12",
  "overallRating": "Good",
  "ratingSafe": "Good",
  "ratingEffective": "Good",
  "ratingCaring": "Good",
  "ratingResponsive": "Good",
  "ratingWellLed": "Good",
  "ratingStatus": "Rated",
  "latestReportDate": "2023-01-14",
  "latestReviewDate": "2023-07-06",
  "dateOfLatestCheck": "2023-01-14",
  "enforcementFlags": "",
  "specialismsServices": "Accommodation for persons who require nursing or personal care; Learning disabilities",
  "alsoKnownAs": "",
  "cqcLocationUrl": "https://www.cqc.org.uk/location/1-119125834",
  "enriched": true,
  "httpStatus": 200,
  "pageError": false,
  "scrapedAt": "2026-11-22T17:02:42.976Z"
}
```

A location that is in a care home / accommodation scope also gets `bedCapacity` filled from its registration conditions:

```json
{
  "locationName": "Haydon Park Lodge",
  "serviceType": "Residential homes",
  "bedCapacity": "13",
  "overallRating": "Good",
  "ratingSafe": "Good",
  "ratingWellLed": "Good",
  "localAuthority": "Merton",
  "cqcLocationUrl": "https://www.cqc.org.uk/location/1-118875948"
}
```

#### Field notes

- `ratingStatus` is one of `Rated`, `Partially rated`, `Not yet rated`, `Not rated by CQC (service type outside rating scope)`. Use it to avoid reading a blank as a low rating.
- `bedCapacity` is published only for accommodation services and only as a registration condition, so it is empty for homecare agencies, GPs, dentists and clinics. In the SW test sample, 9 of 10 accommodation locations returned a capacity.
- `enforcementFlags` is built from what CQC actually publishes on the profile. `enforcement-action` is set for any location that CQC rates **Inadequate**, which CQC itself defines as *"the service is performing badly and we've taken enforcement action against the provider"*. Any explicit `special measures`, `warning notice` or `section 29` wording in the location's own content is appended as well (`special-measures`, `warning-notice`, `warning-notice-s29`). The static rating-legend modal and the "Regulations met / Not all regulations met" tick-and-cross vocabulary are deliberately **excluded** so a legend sentence never becomes a false flag. It is empty for compliant locations, which is the correct answer, not a failure: in the 25-location SW test none were rated Inadequate, so the column was legitimately blank on every row.
- `latestReviewDate` is the "Latest review" date CQC shows on the profile; it is empty where CQC has not published a review for that location.
- `pageError: true` means the location page could not be read; the CSV fields are still returned so a run never silently loses rows.

***

### Cost and speed

Real numbers from three local runs on the final build (streaming CSV, 512 MB container, no proxy). Every figure is measured, not estimated.

**Run A - baseline, 25 enriched SW London locations** (`postcodePrefixes: ["SW"]`, `includeSubRatings: true`, `maxItems: 25`, residential + GP + dental mix):

| Stage | Measured |
|---|---|
| CSV download and stream-parse (18.2 MB, 57,191 data rows) | 4.3 s |
| Row-level prefilters inside the stream (stop after 25 matches) | < 0.2 s |
| 25 location pages, 4 concurrent, 200 ms delay | 11.0 s of HTTP work |
| 10 registration pages for the accommodation locations | included above |
| **Total run, wall clock** | **18.0 s** (16.5 s inside the Actor, rest is Node startup) |
| Per enriched location (page + registration where needed) | **0.66 s** |
| Page failures / rating-filtered out | 0 / 0 |
| **Peak memory (Node RSS)** | **229 MB** |

**Run B - full register, no enrichment** (`includeSubRatings: false`, `maxItems: 0`):

| Stage | Measured |
|---|---|
| Rows scanned from the stream | 57,191 / 57,191 |
| Items pushed to the dataset (batches of 500) | 57,191 |
| HTTP page requests | 0 |
| **Total run, wall clock** | **2 min 57 s** |
| **Peak memory (Node RSS)** | **176 MB** |

**Run C - the money feature, Inadequate providers** (`filterByRating: ["Inadequate"]`, `includeSubRatings: true`, `maxItems: 5`, no postcode filter):

| Stage | Measured |
|---|---|
| Rating prefilter from the CQC search listing | 79 active Inadequate locations found |
| Rows scanned before the cap was filled | 48,371 |
| Items emitted (hard-capped at `maxItems`) | 5 |
| Failures | 0 |
| **Total run, wall clock** | **11.5 s** |
| **Peak memory (Node RSS)** | **225 MB** |

Peak RSS is sampled every 200 ms from `/proc/<pid>/status` (`VmHWM`), so it is the true high-water mark, not an average. The Actor streams the CSV from disk row by row and never holds the parsed 57k-row array, so the full-register run uses less memory than a small enriched run: memory is driven by the crawler, not by the directory size.

On the Apify platform a run in a **512 MB** container (`apify/actor-node:22`, no proxy) costs a few cents of compute. Rough guide:

- **100 locations, enriched**: about 40 seconds of wall clock, a penny or two of compute.
- **2,000 locations, enriched, no proxy**: ~22 minutes at 4 concurrent requests (measured 0.66 s per location).
- **Full register, no enrichment** (`includeSubRatings: false`): 57,191 rows in under 3 minutes on 512 MB, no page requests at all.
- **Full register enriched**: roughly 3 hours at the polite default. `maxConcurrency` goes up to 8 if you accept the extra load; CQC answered every request in these tests without throttling, and the Actor backs off on 429/5xx automatically.
- **Memory**: the Actor requests 512 MB and peaks at 176-229 MB in the runs above, so a full 57k-register run runs comfortably inside 512 MB with headroom for Apify's own overhead.

No proxy is required. Residential proxy groups are supported by Apify's platform if you ever want extra throughput, but this Actor was tested at a $0 proxy budget.

***

### Data source and compliance

- Source: the Care Quality Commission public directory (`cqc.org.uk/system/files/.../CQC_directory.csv`) and public location pages. Crown copyright, published under the **Open Government Licence v3.0** — commercial reuse is permitted; attribution is required (see `attribution` and `disclaimer` in the run's `OUTPUT_SUMMARY` key-value record).
- The Actor reads only public pages, at a polite rate, with no login, no CAPTCHA bypass and no personal data beyond what CQC itself publishes about a registered location (including the registered manager's name, which forms part of the public register).
- CQC data can lag the real world: a rating shown here is the rating at scrape time, not a live guarantee. `scrapedAt` on every record tells you exactly when it was read.

### Run metadata

Each run also writes two key-value records:

- `STATS` — CSV rows read, rows after filters, pages fetched, pages failed, registration pages, runtime.
- `OUTPUT_SUMMARY` — the same figures plus the filters you used, the CSV edition date, and licence/attribution text for your exports.

### Support

Found a page that does not parse, or need a field this Actor does not cover yet? Open an issue on the Actor's Issues tab with the CQC location URL and the run ID — that is enough to reproduce it.
\#� �a�c�t�o�r�1�-�a�p�i�f�y��
�

# Actor input Schema

## `serviceTypes` (type: `array`):

Keep only these CQC service types. Case-insensitive partial match, e.g. "Residential homes" matches every residential care home; "Dentist" matches dental practices. Leave empty for all types. Common values: Residential homes, Nursing homes, Homecare agencies, Supported living, Dentist, Doctors/GPs, Clinic, Hospice, Hospital, Extra Care housing.

## `regions` (type: `array`):

Keep only locations in these CQC regions. Case-insensitive partial match. Values are: London, South East, South West, East of England, Midlands, North East and Yorkshire, North West.

## `postcodePrefixes` (type: `array`):

Keep only locations whose postcode starts with these prefixes. Spaces and case are ignored, so "SW", "E1" and "m1" all work. Great for city-level or territory-based targeting.

## `excludePostcodePrefixes` (type: `array`):

Optional. Drop locations whose postcode starts with these prefixes, e.g. use \["N", "E"] to trim north and east London out of a wider London pull.

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

Optional. Exact local authority names as CQC records them, e.g. "Wandsworth", "Manchester", "Kent". Case-insensitive.

## `providerName` (type: `string`):

Partial match on the location name or the provider (operator) name. Useful for tracking one group: e.g. "Barchester", "HC-One", "Nuffield".

## `includeSubRatings` (type: `boolean`):

When on, each location that survives your filters gets one polite HTTP request to its public CQC page to collect the overall rating, all five key-question sub-ratings (Safe, Effective, Caring, Responsive, Well-led), report date, specialisms, registered manager and enforcement signals. The official CSV has none of these. Turn off for a lightning-fast directory-only pull.

## `filterByRating` (type: `array`):

Optional. Applied after enrichment, on the overall rating (or on any sub-rating when the next switch is on). Typical B2B trigger lists: \["Inadequate", "Requires improvement"] for providers under pressure, \["Outstanding"] for flagship groups. Requires "Fetch ratings and inspection details".

## `matchAnySubRating` (type: `boolean`):

When on, a location is kept if ANY of its five sub-ratings matches your rating list, even if its overall rating does not. This is how you surface homes rated Good overall but Requires improvement on Safe.

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

Safety cap so test runs stay fast and cheap. Default 100; 0 means unlimited (use only when you really want the whole filtered register). When a rating filter is set the cap applies to results pushed, so the Actor keeps enriching until it fills the cap.

## `maxConcurrency` (type: `integer`):

How many CQC pages to fetch at once. 4 is the measured default and keeps peak memory around 230 MB even on long enriched runs; up to 8 works but costs memory. No proxy needed.

## `requestDelaySecs` (type: `number`):

Minimum gap between two requests to the same CQC host. 0.2s is plenty; raise it if you run the full 57k directory.

## `requestTimeoutSecs` (type: `integer`):

Per-page timeout for the CQC location pages.

## `cacheDirectory` (type: `boolean`):

Keeps the 19 MB official CSV in the key-value store and reuses it for 24 hours, so repeated or split runs do not re-download it.

## Actor input object example

```json
{
  "serviceTypes": [
    "Residential homes",
    "Nursing homes"
  ],
  "regions": [
    "London"
  ],
  "postcodePrefixes": [
    "SW",
    "E1",
    "M1"
  ],
  "excludePostcodePrefixes": [],
  "localAuthorities": [],
  "providerName": "",
  "includeSubRatings": true,
  "filterByRating": [],
  "matchAnySubRating": false,
  "maxItems": 100,
  "maxConcurrency": 4,
  "requestDelaySecs": 0.2,
  "requestTimeoutSecs": 45,
  "cacheDirectory": true
}
```

# Actor output Schema

## `careProviders` (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 = {
    "serviceTypes": [],
    "regions": [],
    "postcodePrefixes": [],
    "excludePostcodePrefixes": [],
    "localAuthorities": [],
    "providerName": "",
    "includeSubRatings": true,
    "filterByRating": [],
    "matchAnySubRating": false,
    "maxItems": 100,
    "maxConcurrency": 4,
    "requestDelaySecs": 0.2,
    "requestTimeoutSecs": 45,
    "cacheDirectory": true
};

// Run the Actor and wait for it to finish
const run = await client.actor("kailouis_labs/uk-cqc-care-providers-sub-ratings-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 = {
    "serviceTypes": [],
    "regions": [],
    "postcodePrefixes": [],
    "excludePostcodePrefixes": [],
    "localAuthorities": [],
    "providerName": "",
    "includeSubRatings": True,
    "filterByRating": [],
    "matchAnySubRating": False,
    "maxItems": 100,
    "maxConcurrency": 4,
    "requestDelaySecs": 0.2,
    "requestTimeoutSecs": 45,
    "cacheDirectory": True,
}

# Run the Actor and wait for it to finish
run = client.actor("kailouis_labs/uk-cqc-care-providers-sub-ratings-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 '{
  "serviceTypes": [],
  "regions": [],
  "postcodePrefixes": [],
  "excludePostcodePrefixes": [],
  "localAuthorities": [],
  "providerName": "",
  "includeSubRatings": true,
  "filterByRating": [],
  "matchAnySubRating": false,
  "maxItems": 100,
  "maxConcurrency": 4,
  "requestDelaySecs": 0.2,
  "requestTimeoutSecs": 45,
  "cacheDirectory": true
}' |
apify call kailouis_labs/uk-cqc-care-providers-sub-ratings-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,kailouis_labs/uk-cqc-care-providers-sub-ratings-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/sQ55ZgmoZq85d2IUK/builds/rLsTR7EaoTWy8w1v8/openapi.json
