Food & Drink — entry 009 of 19

Open Food Facts

Verified Sep 2026

Open Food Facts is a crowdsourced, open database of food products worldwide, covering ingredients, nutrition facts, allergens, and Nutri-Score/Eco-Score ratings, with full bulk exports available alongside the live API. A live GET against the real gateway, world.openfoodfacts.org, returned a genuine product record while carrying Access-Control-Allow-Origin: *, resolving cors unknown -> yes; auth None was reconfirmed by the same keyless 200.

Open Food Facts is a free, crowdsourced database of food products worldwide — ingredients, nutrition facts, allergens, and Nutri-Score/Eco-Score ratings, looked up by barcode or full-text search. A live GET this run against a filter-less /search returned {"count":4654144,...} — a live, dated counter, not a fixed fact — and a real product lookup returned genuine data with no credentials.

food-dataopen-datanutritionbarcode
AuthenticationNone requiredCall it straight away — no key, no signup.
HTTPSSupportedTraffic is encrypted in transit.
CORSEnabledCallable directly from browser JavaScript.
PricingFreeNo paid tier — free for the documented use case.
FormatsJSON, CSVResponses can be requested as JSON or CSV.

GreatAPIs Score

Score100out of 100
Authentication25/25No authentication required
Pricing20/20Free to use
Docs20/20Machine-readable spec file bundled
Formats15/15Supports 2 response formats
Freshness20/20Verified within 6 months

Embed this badge

Scored 100 on greatapis.com
<a href="https://greatapis.com/api/open-food-facts/"><img src="https://greatapis.com/badge/open-food-facts.svg" alt="Scored 100 on greatapis.com"></a>

Auth quickstart

  1. No API key, signup, or credit card required — a live GET this run against /product/737628064502.json returned a genuine product record with zero credentials, carrying access-control-allow-origin: * so a browser fetch() works too.
Stored keyNo key stored

Your key is stored only in this browser (localStorage) and sent directly to the API — never to greatapis.

Endpoints

Servers
https://world.openfoodfacts.org
Auth
userAgentAuth
Products1

Endpoints for managing product data and information.

GET/api/v2/product/{code}Get Product Details
Parameters
NameInRequiredType
codepathyesstring
product_typequerynostring
ccquerynostring
lcquerynostring
fieldsquerynostring
knowledge_panel_clientquerynostring
activate_knowledge_panels_simplifiedquerynoboolean
activate_knowledge_panel_physical_activitiesquerynoboolean
knowledge_panels_includedquerynostring
knowledge_panels_excludedquerynostring
blamequerynostring
Responses
StatusDescriptionSchema
200OK—
302Redirect to the correct server for the product type of the requested product—
404Product not found—
Images1

Endpoints for uploading, cropping, rotating, and managing product images.

GET/cgi/product_image_crop.plRotate Image
Parameters
NameInRequiredType
codequeryyesstring
idqueryyesstring
imgidqueryyesstring
anglequeryyesstring
Responses
StatusDescriptionSchema
200OKRotateAPhoto
Search1

Endpoints for searching products with various filters and criteria.

GET/api/v2/searchSearch Products
Parameters
NameInRequiredType
additives_tagsquerynostring
allergens_tagsquerynostring
brands_tagsquerynostring
categories_tagsquerynostring
countries_tags_enquerynostring
emb_codes_tagsquerynostring
labels_tagsquerynostring
manufacturing_places_tagsquerynostring
nutrition_grades_tagsquerynostring
origins_tagsquerynostring
packaging_tags_dequerynostring
purchase_places_tagsquerynostring
states_tagsquerynostring
stores_tagsquerynostring
traces_tagsquerynostring
<tag_name>_tags_<language_code>querynoobject
<nutrient>_lt_<value>querynoobject
<nutrient>_gt_<value>querynoobject
<nutrient>_eq_<value>querynoobject
fieldsquerynostring
sort_byquerynostring
pagequerynointeger
page_sizequerynointeger
Responses
StatusDescriptionSchema
200OKSearchForProducts
OCR1

Endpoints for optical character recognition on product labels.

GET/cgi/ingredients.plOCR on Ingredients
Parameters
NameInRequiredType
idqueryyesstring
codequeryyesstring
process_imagequeryyesstring
ocr_enginequeryyesstring
Responses
StatusDescriptionSchema
200OKOcrOnProduct
Suggestions1

Endpoints for getting suggestions to aid in product editing.

GET/cgi/suggest.plGet Suggestions
Parameters
NameInRequiredType
tagtypequeryyesstring
termquerynostring
Responses
StatusDescriptionSchema
200OK—
Nutrients1

Endpoints for retrieving nutrition-related data and facts.

GET/cgi/nutrients.plGet Nutrients List
Parameters
NameInRequiredType
ccquerynostring
lcquerynostring
Responses
StatusDescriptionSchema
200OKNutrients
Personal Search2

Endpoints for personalized search and recommendations.

GET/api/v2/attribute_groupsGet Attribute Groups
Parameters
NameInRequiredType
lcquerynostring
Responses
StatusDescriptionSchema
200OKGetAttributeGroups
GET/api/v2/preferencesGet Preferences Weights
Parameters
NameInRequiredType
lcquerynostring
Responses
StatusDescriptionSchema
200OKGetPreferences

Try it

Developer reference

Base URLhttps://world.openfoodfacts.org/api/v2
Rate limit

15 requests/minute per IP for read product queries, 10 requests/minute per IP for search queries

Key endpoints
  • GET/api/v2/product/{code}
  • GET/api/v2/search

Gotchas & limits

  • A barcode that doesn't exist is HTTP 200 with "status":0, not a 404 — a live GET this run against /product/0000000000000.json returned 200 {"code":"00000000","status":0,"status_verbose":"no code or invalid code"} and no product key at all. Always check the status field in the body; the HTTP status code alone can't tell success from a miss.
  • /search needs at least one real filter to be reliable — a live GET this run against /search?categories_tags=en:sodas&page_size=2 returned a genuine {count, page, page_count, page_size, products} envelope, but a bare filter-less /search intermittently returned a 503 Page temporarily unavailable maintenance page instead of JSON on the same run. Don't rely on an unfiltered search in production code.
  • The stored url (world.openfoodfacts.org/data) is a bulk-export documentation page, not the API gateway — the real gateway used above, world.openfoodfacts.org/api/v2, is a different path on the same host and isn't linked from that page.

Availability

Uptime50%
Median latency1481.5 ms
Last checkUp · 200 · Sep 2026

16 checks since Aug 2026. A person runs this check by hand, not an automated monitor.