# ClinicalTrials.gov Scraper: Clinical Trials, Sites & Contacts (`best_celerytop/clinical-trials-scraper`) Actor

Clinical trials scraper for ClinicalTrials.gov. Search by condition, drug, sponsor, location, phase and status. One row per study: title, status, phase, sponsor, enrollment, dates, eligibility, outcomes, every study site with coordinates and recruitment contacts. Official API, no login, no proxies.

- **URL**: https://apify.com/best_celerytop/clinical-trials-scraper.md
- **Developed by:** [Konstantin Semin](https://apify.com/best_celerytop) (community)
- **Categories:** Business, Developer tools, AI
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.10 / 1,000 studies

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

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

## Clinical Trials Scraper: ClinicalTrials.gov Studies, Sites & Contacts

Search [ClinicalTrials.gov](https://clinicaltrials.gov), the world's largest registry of clinical studies (500,000+ trials in 200+ countries), and get one clean row per study: title, recruitment status, phase, sponsor, enrollment, start and completion dates, conditions, interventions, eligibility criteria, primary outcomes, every study site with coordinates, and the trial site contacts exactly as published on ClinicalTrials.gov.

The Actor uses the official ClinicalTrials.gov API. No login, no browser, no proxies, no API key, and the data is exactly what the registry publishes.

### What you can do with it

- **Patient recruitment and referral**: find recruiting trials for a condition near a city or in a country, with the trial site contacts the registry publishes for research and site feasibility.
- **Competitive intelligence for pharma and biotech**: track a competitor's pipeline by sponsor or drug name, watch for new phase 3 starts, terminations and status changes.
- **Site selection and feasibility (CROs)**: see which hospitals run trials in an indication and how many sites each study has.
- **Investor and analyst research**: enrollment sizes, primary completion dates and results posting for a company's studies.
- **Monitoring**: schedule a run with "Updated since" to get only records changed since your last check.
- **Research datasets**: thousands of studies with structured design and eligibility fields for analysis or AI pipelines.

### Input

| Field | Type | Description |
|---|---|---|
| `conditions` | array | Diseases or conditions, for example `breast cancer`, `type 2 diabetes`. Any of them matches. |
| `interventions` | array | Drugs, devices, procedures, for example `pembrolizumab`, `semaglutide`. |
| `keywords` | array | Any other terms searched across the whole record. |
| `sponsor` | string | Sponsor or collaborator name, for example `Pfizer`, `Mayo Clinic`. |
| `location` | string | City, state or country of the study sites, for example `Germany`, `Boston`. |
| `statuses` | array | `RECRUITING`, `NOT_YET_RECRUITING`, `ENROLLING_BY_INVITATION`, `ACTIVE_NOT_RECRUITING`, `COMPLETED`, `SUSPENDED`, `TERMINATED`, `WITHDRAWN`, `UNKNOWN`. Empty means all. |
| `phases` | array | `EARLY_PHASE1`, `PHASE1`, `PHASE2`, `PHASE3`, `PHASE4`, `NA`. Empty means all. |
| `studyType` | string | `ALL` (default), `INTERVENTIONAL`, `OBSERVATIONAL`, `EXPANDED_ACCESS`. |
| `updatedSince` | string | `YYYY-MM-DD`. Only studies updated on or after this date. |
| `startedSince` | string | `YYYY-MM-DD`. Only studies starting on or after this date. |
| `withResultsOnly` | boolean | Only studies with posted results. |
| `sortBy` | string | `relevance` (default), `lastUpdated`, `newestPosted`, `startDate`, `enrollment`. |
| `nctIds` | array | Specific studies by NCT number, for example `NCT04280705`. |
| `includeLocations` | boolean | Add every study site with city, country, coordinates, status and site contacts. Default `true`. |
| `maxLocationsPerStudy` | integer | Cap on sites listed per study. Default `100`. |
| `includeEligibilityText` | boolean | Include the full inclusion and exclusion criteria text. Default `true`. |
| `maxItems` | integer | Maximum number of studies saved. Default `100`. |

#### Example input

```json
{
    "conditions": ["breast cancer"],
    "interventions": ["pembrolizumab"],
    "statuses": ["RECRUITING", "NOT_YET_RECRUITING"],
    "phases": ["PHASE2", "PHASE3"],
    "location": "Germany",
    "sortBy": "lastUpdated",
    "maxItems": 200
}
```

### Output

One dataset item per study.

```json
{
    "nctId": "NCT06841354",
    "url": "https://clinicaltrials.gov/study/NCT06841354",
    "title": "A Study of Sacituzumab Tirumotecan as Monotherapy and in Combination With Pembrolizumab in Participants With Triple-Negative Breast Cancer",
    "officialTitle": "A Phase 3, Randomized, Open-label Study Comparing Efficacy and Safety of ...",
    "acronym": null,
    "overallStatus": "RECRUITING",
    "whyStopped": null,
    "studyType": "INTERVENTIONAL",
    "phases": ["PHASE3"],
    "conditions": ["Triple Negative Breast Neoplasms"],
    "keywords": ["Antibody-drug conjugate (ADC)", "TROP2"],
    "meshConditions": ["Triple Negative Breast Neoplasms"],
    "interventions": [{ "type": "BIOLOGICAL", "name": "Sacituzumab tirumotecan", "otherNames": ["MK-2870"] }],
    "armGroups": [{ "label": "Arm A: Sacituzumab Tirumotecan", "type": "EXPERIMENTAL", "interventionNames": ["Biological: Sacituzumab tirumotecan"] }],
    "leadSponsor": "Merck Sharp & Dohme LLC",
    "leadSponsorClass": "INDUSTRY",
    "collaborators": [],
    "organization": "Merck Sharp & Dohme LLC",
    "isFdaRegulatedDrug": true,
    "isFdaRegulatedDevice": false,
    "enrollmentCount": 1000,
    "enrollmentType": "ESTIMATED",
    "allocation": "RANDOMIZED",
    "interventionModel": "PARALLEL",
    "masking": "NONE",
    "primaryPurpose": "TREATMENT",
    "startDate": "2025-03-16",
    "startDateType": "ACTUAL",
    "primaryCompletionDate": "2030-05-18",
    "completionDate": "2030-05-18",
    "firstPostedDate": "2025-02-24",
    "lastUpdatePostedDate": "2026-11-10",
    "resultsFirstPostedDate": null,
    "hasResults": false,
    "briefSummary": "The purpose of this study is to ...",
    "sex": "ALL",
    "minimumAge": "18 Years",
    "maximumAge": null,
    "ageGroups": ["ADULT", "OLDER_ADULT"],
    "healthyVolunteers": false,
    "eligibilityCriteria": "Inclusion Criteria:\n\n* Has locally recurrent unresectable or metastatic TNBC ...",
    "primaryOutcomes": [{ "measure": "Progression-Free Survival (PFS)", "timeFrame": "Up to approximately 5 years" }],
    "secondaryOutcomesCount": 6,
    "centralContacts": [{ "name": "Toll Free Number", "role": "CONTACT", "phone": "1-888-577-8839", "phoneExt": null, "email": "Trialsites@msd.com" }],
    "overallOfficials": [{ "name": "Medical Director", "role": "STUDY_DIRECTOR", "affiliation": "Merck Sharp & Dohme LLC" }],
    "locationsCount": 312,
    "countries": ["United States", "Germany", "Japan"],
    "locations": [
        {
            "facility": "USA Mitchell Cancer Institute ( Site 0090)",
            "city": "Mobile",
            "state": "Alabama",
            "zip": "36604",
            "country": "United States",
            "status": "RECRUITING",
            "latitude": 30.69436,
            "longitude": -88.04305,
            "contacts": [{ "name": "Study Coordinator", "role": "CONTACT", "phone": "251-410-4924", "phoneExt": null, "email": null }]
        }
    ],
    "scrapedAt": "2026-11-12T07:00:00.000Z"
}
```

Fields the registry does not have for a study are `null` or empty lists. Dates are as posted by the registry: full `YYYY-MM-DD` or month-only `YYYY-MM`.

A `RUN_SUMMARY` record in the key-value store tells how many studies matched the search and how many were saved.

### Good to know

- **Scale.** The API returns up to 1,000 studies per request, so a run can collect tens of thousands of studies in a few minutes.
- **Updated since.** Schedule a daily run with `updatedSince` set to yesterday to receive every record that changed, including new trials, status changes and new sites.
- **Several conditions or drugs.** Items within one field are combined with OR; different fields are combined with AND. `conditions: ["lung cancer"]` plus `interventions: ["osimertinib"]` means lung cancer studies of osimertinib.
- **Search syntax.** Each field accepts the registry's own search expressions, so `"small cell" AND NOT mesothelioma` works in `conditions`.
- **Polite by design.** The Actor calls the public API with a small delay between pages and a plain user agent.
- **Price.** $3 per 1,000 studies, no start fee; platform usage is included.
- **Works with n8n, Make, Zapier and AI agents.** The official Apify node for n8n runs this Actor and returns the rows inside a workflow, Make and Zapier use the Apify integration, and AI agents call it as a tool through the Apify MCP server.

### FAQ

**Is this the same data as on the website?**
Yes. The registry's website and this Actor read the same API, so the records are identical and update at the same time.

**Can I get trials from the EU or other registries?**
This Actor covers ClinicalTrials.gov, which also lists most international industry trials. EU CTR, ISRCTN and WHO ICTRP are separate registries and are not included.

**How do I export ClinicalTrials.gov search results to Excel?**
Run the search with your condition, drug or sponsor and download the dataset as Excel, CSV or JSON.

**Does ClinicalTrials.gov have an API?**
Yes, the registry's API version 2. The Actor uses it, so the data is identical to the website.

**How do I find recruiting trials near a city?**
Set `statuses` to `RECRUITING`, put the city or country in `location`, and every study comes with its sites, coordinates and recruitment contacts.

**Can I use it from n8n or an AI agent?**
Yes. Start it through the official Apify node for n8n, the Make or Zapier integration, or the Apify MCP server, and read the rows back from the dataset.

**Something is missing or broken?**
Open an issue on the Issues tab and include the input you used.

### Disclaimer

This Actor is an independent tool. It is not affiliated with, endorsed by or sponsored by the U.S. National Library of Medicine or ClinicalTrials.gov. Study data belongs to the respective sponsors and investigators and is provided for informational purposes; it is not medical advice.

# Actor input Schema

## `conditions` (type: `array`):

Diseases or conditions, one per line, for example `breast cancer`, `type 2 diabetes`, `Alzheimer`. Studies matching any of them are returned.

## `interventions` (type: `array`):

Drugs, devices, procedures or other treatments, for example `pembrolizumab`, `semaglutide`, `CAR-T`.

## `keywords` (type: `array`):

Any other terms searched across the whole study record, for example `biomarker`, `telemedicine`, `NCT04280705`.

## `sponsor` (type: `string`):

Name of the sponsor or collaborator, for example `Pfizer`, `National Cancer Institute`, `Mayo Clinic`.

## `location` (type: `string`):

City, state or country of the study sites, for example `Germany`, `Boston`, `California`.

## `statuses` (type: `array`):

Keep studies with any of these statuses. Leave empty for all.

## `phases` (type: `array`):

Keep studies in any of these phases. Leave empty for all.

## `studyType` (type: `string`):

Interventional studies test a treatment; observational studies only follow participants.

## `updatedSince` (type: `string`):

Only studies whose record was updated on or after this date. Useful for scheduled runs that watch for changes.

## `startedSince` (type: `string`):

Only studies with a start date on or after this date.

## `withResultsOnly` (type: `boolean`):

Keep only studies that have posted results on the registry.

## `sortBy` (type: `string`):

Order of the results.

## `nctIds` (type: `array`):

Fetch specific studies by their NCT number, for example `NCT04280705`. Can be combined with a search.

## `includeLocations` (type: `boolean`):

Add every study site with city, country, coordinates, recruitment status and site contacts.

## `maxLocationsPerStudy` (type: `integer`):

Cap on the number of sites listed for one study. Large trials can have hundreds.

## `includeEligibilityText` (type: `boolean`):

Add the complete inclusion and exclusion criteria text to every study.

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

Maximum number of studies saved in the run.

## Actor input object example

```json
{
  "conditions": [
    "breast cancer"
  ],
  "statuses": [
    "RECRUITING"
  ],
  "studyType": "ALL",
  "withResultsOnly": false,
  "sortBy": "lastUpdated",
  "includeLocations": true,
  "maxLocationsPerStudy": 100,
  "includeEligibilityText": true,
  "maxItems": 50
}
```

# Actor output Schema

## `studies` (type: `string`):

ClinicalTrials.gov studies with design, dates, eligibility, sites and contacts.

## `runSummary` (type: `string`):

How many studies matched and were saved, and any error.

# 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 = {
    "conditions": [
        "breast cancer"
    ],
    "statuses": [
        "RECRUITING"
    ],
    "sortBy": "lastUpdated",
    "maxItems": 50
};

// Run the Actor and wait for it to finish
const run = await client.actor("best_celerytop/clinical-trials-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 = {
    "conditions": ["breast cancer"],
    "statuses": ["RECRUITING"],
    "sortBy": "lastUpdated",
    "maxItems": 50,
}

# Run the Actor and wait for it to finish
run = client.actor("best_celerytop/clinical-trials-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 '{
  "conditions": [
    "breast cancer"
  ],
  "statuses": [
    "RECRUITING"
  ],
  "sortBy": "lastUpdated",
  "maxItems": 50
}' |
apify call best_celerytop/clinical-trials-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,best_celerytop/clinical-trials-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/Ukf4Ps1k6hgmN9AFP/builds/zDe5lJIWvFPI1WiCm/openapi.json
