API Home
If you are looking for information about clinical studies, please visit ClinicalTrials.gov.
Notice to API users:

Starting in April, users of the classic ClinicalTrials.gov API may experience brief disruptions in API service during a series of planned outages. These outages are intended to identify and support the API users who need to migrate to the modernized ClinicalTrials.gov API version 2.0, as the classic ClinicalTrials.gov API will retire in June 2024. To make this transition, users have the following options:

  • Migrate to the new API (preferred solution)
  • Migrate to the legacy endpoint replacements in the Migration Guide

Please read the updated Modernization Transition Top Questions for more information or contact us at register@clinicaltrials.gov with any questions.

The ClinicalTrials.gov application programming interface (API) provides a toolbox for programmers and other technical users to use to access all posted information on ClinicalTrials.gov study records data. The API is designed for encoding simple and complex search expressions and parameters in URLs. Clicking on query URLs retrieves study records from ClinicalTrials.gov. Use of ClinicalTrials.gov data is subject to these Terms and Conditions.

Documentation

Use the following links to learn about the ClinicalTrials.gov API.
Link Description
API URLs List of info URLs for accessing information about the API and query URLs with parameters.
Query URL Responses Description of information returned by query URLs.
Search Expressions and Syntax Types and syntax of search expressions used in query URLs.
Search Operators List of operators with examples and descriptions of search expressions used in query URLs.
Data Element-to-API Field Crosswalks List of ClinicalTrials.gov data elements and their corresponding API fields.
Study Structure and Fields Organization of API fields within a ClinicalTrials.gov study record and other information.
Search Areas List and description of ways to specify the portions of a study record to search, ranging from multiple API fields (e.g., BasicSearch, ConditionsSearch) to a single field (e.g., Acronym).
Download Content for All Study Records URLs for downloading all content for all study records available on ClinicalTrials.gov as a single zip file.

Interactive Demonstrations

Use the following demonstrations to explore and develop the three types of query URLs available for accessing different levels of API data from ClinicalTrials.gov. After specifying the parameter values in the Request section on a demonstration page and clicking on "Send Request," the Response section will display the resulting URL that was sent to ClinicalTrials.gov to generate the response.
Query URL Type Description Example
Full Studies Retrieves all content from the first study record returned for a submitted query by default. Returns up to 100 study records per query when the minimum rank and maximum rank parameters are set in a query URL and up to 10,000 records using the Full Studies interactive demonstration. https://ClinicalTrials.gov/api/query/full_studies?expr=heart+attack
Study Fields Retrieves the values of one or more fields from up to all study records returned for a submitted query by default. Returns up to 1,000 study records per query when the minimum rank and maximum rank parameters are set in a query URL and up to all study records using the Study Fields interactive demonstration. https://ClinicalTrials.gov/api/query/study_fields?expr=heart+attack&fields=NCTId,Condition,BriefTitle
Field Values Retrieves a unique list of values for one study field from all study records returned for a submitted query. https://ClinicalTrials.gov/api/query/field_values?expr=heart+attack&field=Condition