Graph Beta Get a free key

Food Database API

Live

Find a food and get every nutrient with its source: search, autocomplete, details, portions.

Generic foods from USDA FoodData Central and ANSES-CIQUAL with names in five languages, plus dishes and US branded products. Search with filters and nutrients inline, suggest names as people type, fetch one food or a batch, and scale values to any portion.

At a glance

Status
Live
Endpoints
GET /v1/food/search
GET /v1/food/autocomplete
GET /v1/food/foods/{id}
GET /v1/food/foods
GET /v1/food/foods/{id}/nutrients
GET /v1/food/groups
Cost
1 unit (each endpoint)
MCP tools
food_search
food_autocomplete
food_get
food_get_many
food_nutrients_for_portion
food_groups
Data
Food dataset 1.0.0, built 2026-10-10.

Try it

Choose an endpoint and a sample, change the parameters, and send. Without a key the public demo answers the sample requests (marked demo, not counted against any quota, limited per IP address). With your key, or your account when you are signed in, any values work and the call counts against your plan. A key stays in this page's memory: it is never stored. Get a free key.

1 unit per call. Endpoint docs

query, required: Search text

query: Language of the name; non-English names of USDA foods are machine translations (marked as such)

query

query

query

query: Food group (GET /v1/food/groups); returns generic foods only

query: Preparation state; returns generic foods only

query: Source dataset; returns generic foods only

query: Only foods with (true) or without (false) a source portion weight; returns generic foods only

query: Comma-separated nutrient keys to return per 100 g in each result, e.g. energy_kcal,protein_g

Your API key (optional)

Leave empty for the demo. With a key the playground calls the real endpoint from your browser; the key is kept in memory only.

Recorded answer of the real API on the current data for this sample (long arrays trimmed).

Response

Response 200GET/v1/food/search
{
  "data": {
    "query": "chicken breast roasted",
    "lang": "en",
    "type": null,
    "count": 3,
    "results": [
      {
        "id": "fdc:2705956",
        "type": "generic",
        "name": "Chicken breast, baked, broiled, or roasted, skin not eaten, from raw",
        "basis": "100 g",
        "energy_kcal_per_100": 161,
        "energy_provenance": {
          "source": "fdc_survey",
          "record_id": "2705956",
          "source_nutrient_id": "1008",
          "retrieved": "2026-10-10",
          "method": "copied from source"
        },
        "is_preferred": true,
        "matched_name": "Chicken breast, baked, broiled, or roasted, skin not eaten, from raw",
        "matched_lang": "en",
        "score": 6.119,
        "why": ["name is the search words", "state cooked", "… 1 more"]
      },
      {
        "id": "fdc:2705955",
        "type": "generic",
        "name": "Chicken breast, baked, broiled, or roasted, skin eaten, from raw",
        "basis": "100 g",
        "energy_kcal_per_100": 192,
        "energy_provenance": {
          "source": "fdc_survey",
          "record_id": "2705955",
          "source_nutrient_id": "1008",
          "retrieved": "2026-10-10",
          "method": "copied from source"
        },
        "is_preferred": true,
        "matched_name": "Chicken breast, baked, broiled, or roasted, skin eaten, from raw",
        "matched_lang": "en",
        "score": 6,
        "why": ["name is the search words", "state cooked", "… 1 more"]
      },
      "… 1 more"
    ],
    "ranking": "Generic foods and dishes together, by a score computed from the data (each result's score and why): every word as a whole word (not only the start of a longer word), the name starting with the words o…"
  },
  "meta": {
    "request_id": "req_…",
    "api_version": "1",
    "dataset": "food",
    "dataset_version": "1.0.0",
    "dataset_built_at": "2026-10-10T17:56:11Z",
    "data_status": "released",
    "sources": [
      {
        "id": "ah102",
        "name": "USDA Agriculture Handbook No. 102, Food Yields Summarized by Different Stages of Preparation (1975)",
        "url": "https://www.ars.usda.gov/ARSUserFiles/80400525/Data/Classics/ah102.pdf",
        "licence": "U.S. Government work (USDA), public domain in the United States",
        "commercial_redistribution_ok": true,
        "retrieved": "2026-10-10",
        "version": "1975 (scanned PDF, ARS Classics)",
        "attribution": "Matthews RH, Garrison YJ. Food Yields Summarized by Different Stages of Preparation. Agriculture Handbook No. 102, USDA, 1975."
      },
      {
        "id": "ciqual",
        "name": "ANSES-CIQUAL French food composition table 2025 (English edition)",
        "url": "https://ciqual.anses.fr/cms/sites/default/files/inline-files/Table%20Ciqual%202025_ENG_2025_11_03.xlsx",
        "licence": "Licence Ouverte / Open Licence (Etalab). Reuse allowed, including commercial, on condition that the data are not altered, their meaning is not distorted, the source and version date are cited, and no …",
        "commercial_redistribution_ok": true,
        "retrieved": "2026-10-10",
        "version": "2025 (file dated 2025-11-03)",
        "attribution": "Anses. 2025. Ciqual French food composition table."
      },
      "… 8 more"
    ],
    "provenance_note": "Every value carries provenance (source, id or URL, retrieval date; method and confidence where an AI judged). Calculations list their inputs and method.",
    "disclaimer": "Nutrition reference data. Not medical or dietary advice.",
    "usage": "…"
  }
}
  1. 1Pin and diff: the version is also in the X-Dataset-Version header

Request

curlGET/v1/food/search
curl -s "https://api.nutrientgraph.com/demo/v1/food/search?q=chicken+breast+roasted&lang=en&limit=3"

Endpoints

Endpoints of the Food Database API
EndpointWhat it doesCostMCP toolDocumentation
GET /v1/food/searchSearch foods by name1 unitfood_searchDocs
GET /v1/food/autocompleteSuggest food names as you typefreefood_autocompleteDocs
GET /v1/food/foods/{id}Get a food by id1 unitfood_getDocs
GET /v1/food/foodsGet several foods by id1 unit per 5 distinct ids (minimum 1)food_get_manyDocs
GET /v1/food/foods/{id}/nutrientsNutrients for a portion1 unitfood_nutrients_for_portionDocs
GET /v1/food/groupsFood groups and preparation statesfreefood_groupsDocs

What is included

  • Search in English, French, German, Italian or Spanish, with filters by food group, preparation state, source and portion
  • Nutrients inline in search results, so a list needs one call
  • Autocomplete for search-as-you-type, free of charge
  • Every value with its source record, source nutrient id and retrieval date
  • Portions with gram weights from the source, and scaling to any portion
  • Diet and allergen tags Coming soon

How it differs

  • A source on every value: the record, the nutrient id and the retrieval date, not just a number.
  • A value the source does not report stays empty. It is never filled with zero.
  • Caching and use by AI agents are allowed on every plan.

Plans

One key and one plan cover every NutrientGraph product, this one included. Free: 2,500 units a month (2,500 calls of /v1/food/search). Developer $19 and Pro $99 a month. Caching inside your product is allowed, and so is use by AI agents. Plans and units.

Status: Live. All products.