Skip to content
RAG Repo

USDA FoodData Central

FoodData Central (FDC) is the United States Department of Agriculture's food-composition database, managed by the Agricultural Research Service at the Beltsville Human Nutrition Research Center and hosted by the National Agricultural Library. It is the successor to the older National Nutrient Database and gathers several distinct data types under one roof: Foundation Foods (analytical values for commodity and minimally processed samples), SR Legacy (the historical Standard Reference set, with its final update in 2018), Survey Foods from FNDDS (used in the What We Eat in America dietary survey), Experimental Foods, and Branded Foods (label data supplied through a public-private partnership). Between them they record energy, macronutrients, vitamins, minerals and other components per food.

This is a structured reference database rather than a packaged machine-learning corpus, so you shape it to your needs. You can search and browse foods through the web portal, pull individual records in real time through the REST API using a free data.gov key, or take the whole thing from the download page as Excel-compatible CSV or JSON. For a corpus, the bulk download is the sensible route; for lookups, the API suits on-demand resolution. For RAG, one food per passage works well: build a short block naming the food and its key nutrient values so a retriever can answer questions about what a food contains.

The licence position is clean. FDC data are in the public domain under CC0 1.0 Universal, so commercial use is permitted and no permission is needed. USDA asks as a courtesy that you credit FoodData Central as the source, but this is a request, not a legal condition, so attribution is not strictly required. One caveat: Branded Foods entries describe commercial products, and the data licence does not give you the right to imply any brand endorses your work. It sits naturally alongside the sibling food sources we list, Open Food Facts and CoFID, as the authoritative US-centred option among them.

foodnutritionpublic-domainusstructuredapi

Related sources