Microproduct Data GuideBeginner

PubChem Compounds

Chemical identifiers, properties, and bioassay links for building compound lookup and structure-reference tools.

Report a Problem

At a Glance

Difficulty
Beginner — comfortable for a first prototype
Size
Large · ≤20 GB
Formats
JSON, XML, CSV
Access
API or Download
API Key
Not Required
Provider
National Center for Biotechnology Information
Updates
Daily
Last Verified
Aug 18, 2026
Source Type
Government Source
  • Python Syntax Checked
  • Runnable Notebook

From Source to Product Signal

Test a Product Idea in Four Steps

PubChem PUG REST returns compound records by name or CID. Start with one chemical name. Properties can come from predicted or deposited sources, name resolution can hit multiple CIDs, and this is not a regulatory label.

1

Check the Setup

  • Python 3.10 or newer
  • A notebook environment such as Jupyter or Google Colab
  • An internet connection
2

Access the Data

  1. 1.Open the PUG REST documentation and choose the compound-name path.
  2. 2.Request JSON properties for one name such as aspirin.
  3. 3.Keep CID, molecular formula, and molecular weight.
Open Official Source
3

Run the Python Example

Install the packages, then run the notebook cell.

python -m pip install pandas requests

import pandas as pd
import requests

response = requests.get(
    "https://pubchem.ncbi.nlm.nih.gov/rest/pug/compound/name/aspirin/property/MolecularFormula,MolecularWeight,IUPACName/JSON",
    timeout=30,
)
response.raise_for_status()
compounds = pd.DataFrame(response.json()["PropertyTable"]["Properties"])
compounds["retrieved_at_utc"] = pd.Timestamp.now(tz="UTC")
print(compounds)
4

Test a Useful Signal

Look Up Aspirin Identifiers

Test whether PUG REST can power a bounded compound-reference card.

  1. 01Confirm CID, formula, and molecular weight returned for the name query.
  2. 02Compare multiple CIDs if the name resolves to more than one compound.
  3. 03Explain that PubChem properties may be predicted or deposited and are not a DailyMed label.

Dataset Details

National Center for Biotechnology Information is a government source. Last verified 2026-08-18. Temporal coverage: continuously updated compound records.

Geography

Formats

Provider

National Center for Biotechnology Information

Data Terms

NCBI PubChem data-use and copyright terms

Send Feedback