← Tutorials

How to Search Clinical Trials and Eligibility Criteria Using MCP (Step-by-Step Guide for Life Scientists)

Published Nov 3, 2026

0 0 Link copied

1. Introduction: Why Life Scientists Need MCP for Clinical Trial Searches

  • The Problem: Scoping the trial landscape for a disease, or checking whether a patient cohort could qualify for a study, means running filtered searches on ClinicalTrials.gov, opening dozens of study records one by one, and reading long blocks of inclusion and exclusion criteria. Comparing trials side by side usually ends in a hand-built spreadsheet.
  • The Solution: Model Context Protocol (MCP) acts as a secure data bridge between Claude and the live ClinicalTrials.gov registry. Claude runs the filtered search for you, counts and ranks the matching studies, pulls the full record for any trial, and rewrites its eligibility criteria as a structured checklist.

This guide uses the open-source ClinicalTrials.gov MCP server listed in the BenchNBots directory. It uses the official ClinicalTrials.gov API (version 2) and covers study search, full study records, posted results, study counts and patient-to-trial matching.

Research use only: Results are for research, landscaping and education. Trial records change often, and an eligibility checklist is not a screening decision. Patients should always confirm eligibility with the study team.

2. What You Will Achieve in This Tutorial

By the end of this guide, you will:

  1. Connect Claude Desktop to the live ClinicalTrials.gov registry.
  2. Find recruiting trials by condition, phase and country using a plain-English prompt.
  3. Rank and compare trials by sponsor, intervention and target enrollment in one table.
  4. Turn a trial's inclusion and exclusion criteria into a clear checklist you can share with your team.

3. Prerequisites: What Is Needed (Tested & Verified for Claude)

Before getting started, make sure you have:

  • The Claude Desktop App installed on macOS or Windows (Option A also works on claude.ai in your browser).
  • 5 minutes of setup time.
  • For Option B only: Node.js version 24 or later installed on your computer (downloadable for free from nodejs.org).

No API key or programming knowledge is required.

4. Which Setup Option Should You Choose?

There are two ways to connect Claude to ClinicalTrials.gov. Both give Claude the same trial search tools.

Option A: Connector (recommended) Option B: Config file (advanced)
What you do Add one URL in Claude's connector settings Edit a JSON file and restart Claude
Install needed None Node.js 24 or later
Where the server runs A public server hosted by the server's developer On your own computer
Works on Claude Desktop and claude.ai Claude Desktop only
Setup time About 2 minutes About 5 minutes

Choose Option A for the quickest setup. Choose Option B if you'd rather your searches don't pass through a third-party server, or your organisation doesn't allow custom connectors.

5. Option A: Add ClinicalTrials.gov as a Connector (No Install)

Prefer to watch? This 56-second video with voiceover shows every step below, from opening Customize to Claude's first trial search.

▶ Watch this video on YouTube

Step 1: Open Your Connectors

In Claude Desktop (or on claude.ai), click Customize in the sidebar and select the Connectors tab.

Claude's Customize page with Customize selected in the sidebar, the Connectors tab open, and the Add button highlighted

Step 2: Add a Custom Connector

Click + Add, then Add custom connector.

The Add menu on Claude's Customize page showing the Add custom connector option

Fill in the form and click Continue:

  • Name: ClinicalTrials.gov
  • MCP server URL:
https://clinicaltrials.caseyjhand.com/mcp

The Add custom connector form filled in with the name ClinicalTrials.gov and the ClinicalTrials.gov MCP server URL

Step 3: Keep "No sign-in" and Click Add

Claude detects that this server needs no account and selects No sign-in for you. Leave it as it is and click Add. No API key is needed.

The connector authentication options with No sign-in selected and the Add button highlighted

Step 4: Connect

Click Connect on the new connector page.

The ClinicalTrials.gov connector page saying you're not connected yet, with the Connect button highlighted

You'll see Connected to ClinicalTrials.gov and the server's 7 read-only tools, including Clinicaltrials Search Studies, Clinicaltrials Get Study Record, Clinicaltrials Get Study Results and Clinicaltrials Find Eligible. They are set to Needs approval, so Claude asks before each lookup.

The connected ClinicalTrials.gov connector showing its 7 read-only tools set to Needs approval

Step 5: Turn the Connector On in a Chat

Start a new chat, click + below the message box, open Connectors, and make sure ClinicalTrials.gov is switched on. Then go to Run Your First Test Prompt.

The chat tools menu with Connectors open and the ClinicalTrials.gov connector switched on

6. Option B: Run the ClinicalTrials.gov Server on Your Computer (Advanced)

Step 1: Open Your Claude Desktop Configuration File

The easiest way to open it on any computer is in Claude Desktop: go to Settings → Developer → Edit Config. This creates the file if it doesn't exist yet.

  • For macOS users: If you use VS Code, you can also open your terminal and paste this command:
code ~/Library/Application\ Support/Claude/claude_desktop_config.json
  • For Windows users: Press Win + R, paste %APPDATA%\Claude, and open claude_desktop_config.json in any text editor.

Step 2: Add the ClinicalTrials.gov MCP Configuration

Copy and paste the following snippet into your configuration file:

{
  "mcpServers": {
    "clinicaltrials": {
      "command": "npx",
      "args": [
        "-y",
        "clinicaltrialsgov-mcp-server@latest"
      ]
    }
  }
}

If your file already has an "mcpServers" section, add the "clinicaltrials" entry inside it instead of pasting a second one.

Save and close the file.

Step 3: Restart Claude Desktop

Completely quit the Claude Desktop app (ensure it is closed from your system tray or menu bar, not just the window) and reopen it. Claude Desktop only detects new MCP servers when it starts up.

7. Run Your First Test Prompt

Whichever option you chose, paste this exact prompt into a new chat to test your setup:

"Using ClinicalTrials.gov, find Phase 3 trials for Alzheimer's disease that are currently recruiting in the United States. Tell me how many there are and list the 5 largest by target enrollment in a table (NCT ID, title, sponsor, intervention, enrollment). Then pull the full record for NCT07717411 and summarize its key inclusion and exclusion criteria as a checklist."

Claude asks before using each tool, showing exactly what it will look up. Here it uses Clinicaltrials Search Studies with the condition "Alzheimer Disease" and the location "United States". Click Allow once each time, or Always allow if you don't want to be asked again. This question takes two lookups: the search, then the full study record.

Claude asking permission to use the Clinicaltrials Search Studies tool for Alzheimer Disease in the United States, with Allow once highlighted

8. Expected Outcomes

When working correctly, Claude will query the live ClinicalTrials.gov registry instead of relying on training memory, and the answer will be marked Used ClinicalTrials.gov. You should see something like this:

23 trials match (Phase 3, recruiting, Alzheimer's disease, at least one US site). Claude also flags why that number is slightly high: it includes combined Phase 2/3 trials and one off-target transthyretin amyloidosis trial that matched through a broader disease category.

NCT ID Title (short) Sponsor Intervention Enrollment
NCT07177352 Screening study for Alzheimer's trial eligibility Hoffmann-La Roche None (screening only) 80,000
NCT07142954 Epidemiology and biomarker study Eli Lilly and Company P-tau217 blood test 3,400
NCT07717411 Trontinemab in cognitively unimpaired individuals (PrevenTRON) Hoffmann-La Roche Trontinemab vs. placebo 1,600
NCT06159673 ACP-204 in Alzheimer's disease psychosis (Phase 2/3) ACADIA Pharmaceuticals ACP-204 vs. placebo 1,074
NCT05980949 Open-label extension of KarXT (ADEPT-3) Karuna Therapeutics (Bristol Myers Squibb) KarXT 1,000

Notice that Claude points out the top two aren't drug trials, a detail that's easy to miss in a raw search export.

Claude's answer marked Used ClinicalTrials.gov, with the 23-trial count and a table of the 5 largest recruiting Phase 3 Alzheimer's trials, the trontinemab study highlighted

Claude then pulls the full record for NCT07717411 (PrevenTRON): a double-blind trial of IV trontinemab versus placebo in people aged 55–80 with no symptoms but a plasma pTau217 level suggesting future decline. It turns the record's criteria into a checklist: 7 inclusion criteria (such as body weight of 150 kg or less and an available study partner) and exclusion criteria grouped into brain and mental health, other medical conditions, and medications. Examples include mild cognitive impairment or any dementia, any past anti-amyloid antibody, and any use of cholinesterase inhibitors.

Claude's eligibility checklist for NCT07717411, with the Inclusion and Exclusion headings highlighted

We checked the trial count, the top 5 and the eligibility criteria directly against the ClinicalTrials.gov API on 3 November 2026, and they match. The registry updates daily, so your count may differ if you run this later.

A useful habit: Claude also notes when a record says criteria are "defined by the protocol" without giving numbers (here, the exact pTau217 cutoff). Those details are only available from the study team, so check the contact listed on the record.

9. Troubleshooting & FAQs

Q: I can't find "Add custom connector" (Option A).

Fix: On Team and Enterprise plans, only organisation owners can add custom connectors, so ask your admin to add it. If connectors are turned off for your organisation, use Option B instead.

Q: Claude says "Tool execution failed" or doesn't show the ClinicalTrials.gov tools (Option B).

Fix: Check three things:

  1. Node.js 24 or later is installed. Run node --version in your terminal to check.
  2. Your configuration file is valid JSON: no trailing commas, every { and [ closed, and straight quotes (") rather than curly quotes (“ ”). Paste it into a JSON validator such as jsonlint.com if unsure.
  3. You fully quit Claude Desktop (from the menu bar or system tray) before reopening it.

Q: Claude's results are slow, or it reports a rate limit.

Fix: ClinicalTrials.gov allows about one request per second, and the server queues requests to stay under that limit. Large searches across many pages take longer. Narrow your search by phase, status or country, or ask for fewer results per page.

Q: The trial count includes studies that aren't really about my disease.

Fix: ClinicalTrials.gov matches conditions through broader disease categories, so related trials can slip in. Ask Claude to "remove any trial whose listed conditions don't include [your disease]" or to list each trial's conditions so you can check.

Q: Can Claude tell me whether a specific patient qualifies?

A: It can help with a first pass. The Clinicaltrials Find Eligible tool matches age, sex, conditions and location to recruiting trials, and Claude can compare a de-identified profile against a trial's criteria. It can't replace screening by the study team. With Option A your queries pass through the developer's hosted server, and with either option your prompts are processed by Claude like any other conversation, so never include names, dates of birth or other patient identifiers.

10. Quick Quiz: Test Your Knowledge

  1. True or False: If a trial is listed as "Recruiting", every one of its US sites is already enrolling. (Answer: False. "Recruiting" describes the trial as a whole, so some sites may not be open yet.)
  2. Which setup option needs no software installed on your computer? (Answer: Option A, adding the server as a custom connector.)
  3. What must you do after editing claude_desktop_config.json? (Answer: Completely quit and reopen Claude Desktop, because it only detects new MCP servers when it starts.)

Taxonomies