# ClinicalTrials.gov Scraper — Trials & Sponsors (`bovi/clinicaltrials-scraper`) Actor

Scrape the ClinicalTrials.gov registry — trials with status, phase, sponsor, conditions, interventions, enrollment, locations and contacts. Filter by condition, sponsor and status. Official keyless API. Schedule as a pharma/biotech trial monitor. Pay per result.

- **URL**: https://apify.com/bovi/clinicaltrials-scraper.md
- **Developed by:** [Vitalii Bondarev](https://apify.com/bovi) (community)
- **Categories:** Business, AI
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $11.54 / 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/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
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.
Actors are written with capital "A".

## 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.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

## ClinicalTrials.gov Scraper — Trials, Sponsors & Status

Extract structured clinical-trial records from the official **ClinicalTrials.gov**
registry — the U.S. National Library of Medicine database of public and private
clinical studies run around the world. Filter by condition, sponsor and status,
and get clean JSON for every matching trial: status, phase, sponsor, conditions,
interventions, enrollment, eligibility, locations and contacts.

Built on the **official keyless ClinicalTrials.gov API v2** — no login, no API key,
no fragile HTML scraping. Stable, fast, and complete.

### What you get (per study)

| Field | Description |
|---|---|
| `nct_id` | The trial's NCT registry identifier |
| `brief_title` / `official_title` | Short and full study titles |
| `overall_status` | Recruiting, Completed, Terminated, … |
| `phases` | Trial phase(s) — Phase 1/2/3/4 |
| `study_type` | Interventional / Observational |
| `conditions` | Diseases / conditions studied |
| `interventions` | Drugs, devices, procedures tested |
| `lead_sponsor` / `lead_sponsor_class` | Sponsoring organisation + class (Industry / NIH / Other) |
| `collaborators` | Collaborating organisations |
| `enrollment_count` | Target / actual participant count |
| `start_date` / `primary_completion_date` / `completion_date` | Key milestone dates |
| `eligibility_min_age` / `eligibility_max_age` / `eligibility_sex` | Participant eligibility |
| `central_contact_name` / `central_contact_email` | Study contact |
| `locations_count` / `first_location_country` | Site footprint |
| `study_url` | Direct link to the trial page |

### Input

- **`condition`** — disease / condition to search (e.g. `cancer`, `diabetes`).
- **`term`** — any other free-text search term (drug, NCT id, keyword).
- **`sponsor`** — filter by sponsoring organisation.
- **`location`** — filter by trial location.
- **`statuses`** — list of recruitment statuses to include (optional).
- **`maxItems`** — cap the number of studies returned (`0` = all matches).

### Use cases

- **Pharma & biotech competitive intelligence** — track who is running trials for
  a given condition or drug class, and at what phase.
- **Patient-recruitment & site selection** — find recruiting trials by condition,
  geography and eligibility.
- **Market & investment research** — monitor a sponsor's pipeline and milestone dates.
- **Academic & systematic reviews** — pull structured trial metadata at scale.

### Pricing

Pay-per-result: **$0.0119 per study** (`study` event). You pay only for the
records actually returned — no subscription, no minimum. Platform compute runs on
your own Apify account.

### Notes

Data comes from the public ClinicalTrials.gov registry and is provided as-is for
research and intelligence use. The actor reads the official API only.

# Actor input Schema

## `condition` (type: `string`):

Condition or disease to search for (e.g. "breast cancer", "type 2 diabetes"). Maps to query.cond.

## `term` (type: `string`):

Free-text term searched across the study record (drug, keyword). Maps to query.term.

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

Lead sponsor or collaborator name (e.g. "Pfizer", "Novartis"). Maps to query.spons.

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

Location term (country, state or city). Maps to query.locn.

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

Filter by overall status, e.g. RECRUITING, NOT\_YET\_RECRUITING, ACTIVE\_NOT\_RECRUITING, COMPLETED, TERMINATED. Empty = all.

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

Maximum number of studies to return.

## `proxyConfiguration` (type: `object`):

Apify proxy used to reach the API. Residential is the reliable default; the run is billed to your account.

## Actor input object example

```json
{
  "condition": "cancer",
  "statuses": [],
  "maxItems": 100,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}
```

# Actor output Schema

## `results` (type: `string`):

Dataset of clinical studies (nct\_id, brief\_title, overall\_status, study\_type, phases, conditions, lead\_sponsor, enrollment\_count, start\_date, completion\_date, study\_url).

# 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 = {
    "condition": "cancer",
    "proxyConfiguration": {
        "useApifyProxy": true,
        "apifyProxyGroups": [
            "RESIDENTIAL"
        ]
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("bovi/clinicaltrials-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 = {
    "condition": "cancer",
    "proxyConfiguration": {
        "useApifyProxy": True,
        "apifyProxyGroups": ["RESIDENTIAL"],
    },
}

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

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

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

```

## CLI example

```bash
echo '{
  "condition": "cancer",
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}' |
apify call bovi/clinicaltrials-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=bovi/clinicaltrials-scraper",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/ERIV4KgkZUAmrYFly/builds/1oOytxD1FYygFPfq7/openapi.json
