Open Food Facts EAN UPC GTIN Lookup avatar

Open Food Facts EAN UPC GTIN Lookup

Pricing

from $5.04 / 1,000 item extracteds

Go to Apify Store
Open Food Facts EAN UPC GTIN Lookup

Open Food Facts EAN UPC GTIN Lookup

Resolve food-product EAN, UPC, and GTIN barcodes into normalized Open Food Facts identity, ingredient, nutrition, image, provenance, and status records.

Pricing

from $5.04 / 1,000 item extracteds

Rating

0.0

(0)

Developer

Automation Lab

Automation Lab

Maintained by Community

Actor stats

0

Bookmarked

2

Total users

1

Monthly active users

9 days ago

Last modified

Categories

Share

Resolve batches of food-product EAN, UPC, and GTIN barcodes into normalized openfoodfacts records. The Actor returns product identity, brands, categories, ingredients, allergens, nutrition, food scores, images, source revisions, and an explicit status for every unique lookup.

It uses the anonymous Open Food Facts API. No API key, browser, proxy, or customer account is required. No AI model is used. This independently operated Automation Lab Actor is not affiliated with or endorsed by Open Food Facts.

What can you do with this Open Food Facts lookup?

  • Enrich grocery catalogs with product names, brands, package sizes, and categories.
  • Validate barcode lists and separate found, not-found, and temporary lookup-error records.
  • Add ingredients, allergens, Nutri-Score, NOVA group, Eco-Score, and per-100g nutrition to product data.
  • Audit source freshness with Open Food Facts creation, modification, and revision metadata.
  • Run repeatable barcode batches from Apify schedules, API clients, webhooks, or MCP tools.

This Actor is source-specific and food-focused. For a broader multi-database lookup with fewer food-specific fields, use UPC Barcode Product Lookup.

Who is this Actor for?

  • E-commerce catalog teams matching supplier GTINs to readable food-product data.
  • Nutrition and diet app developers importing ingredients and nutrition facts.
  • Data quality teams checking whether barcode identifiers have public product records.
  • Market researchers creating source-attributed food assortments.
  • Automation engineers resolving recurring barcode batches without maintaining an Open Food Facts API client.

Input

Provide codes as strings so leading zeroes are preserved.

FieldTypeDefaultDescription
codesstring arrayrequiredValid EAN-8/GTIN-8, UPC-A, EAN-13, or GTIN-14 barcodes. Spaces and hyphens are accepted.
maxItemsinteger100Maximum unique barcodes processed after deduplication, from 1 to 500.
maxConcurrencyinteger3Maximum concurrent workers, from 1 to 5. All workers and retries share the same rate-aware scheduler; increasing this does not bypass pacing.
{
"codes": ["3017620422003", "5449000000996", "2225954479223"],
"maxItems": 3,
"maxConcurrency": 2
}

Each barcode is validated with its standard GTIN check digit before any request starts. Duplicate inputs are looked up once and reported in duplicateCount.

Output fields

The default dataset contains one row per unique processed barcode.

GroupFields
IdentifierinputCode, gtin, format, status, duplicateCount
IdentityproductName, genericName, brands, categories, quantity
Catalog enrichmentpackaging, packagingTags, stores, traces, servingSize, servingQuantity
IngredientsingredientsText, allergens, labels, countries
ScoresnutriScoreGrade, novaGroup, ecoScoreGrade
NutritionnutritionPer100g.energyKj, nutritionPer100g.energyKcal, fat, saturated fat, carbohydrates, sugars, fiber, proteins, salt, sodium
Imagesimages.front, images.ingredients, images.nutrition
ProvenancesourceUrl, sourceApiUrl, sourceRevision, sourceCreatedAt, sourceLastModifiedAt, lookedUpAt
Failure detailBounded error for invalid responses, exhausted requests, or deadline exhaustion

status is found, not_found, or lookup_error. Missing optional Open Food Facts fields are returned as null or empty arrays rather than guessed. The Lookup diagnostics view exposes status, submitted/normalized code, duplicate count and error; the final run log summarizes found, not-found and error counts. A SUCCEEDED run can contain lookup errors, which do not incur an item event.

packaging is source text; packagingTags preserves raw taxonomy identifiers (including language prefixes). stores and traces are normalized source tags, not live retailer inventory or allergen-safety guarantees. Empty traces do not certify absence. servingSize preserves source text; servingQuantity is the source quantity in g or ml as applicable, with no conversion or inferred units. Energy is source-provided kcal/kJ per 100 g or 100 ml; other nutrition values are grams. Missing serving/nutrition values are not zero.

Example product record

{
"inputCode": "3017620422003",
"gtin": "3017620422003",
"format": "EAN-13",
"status": "found",
"productName": "Nutella",
"brands": ["nutella", "ferrero"],
"categories": ["spreads", "sweet spreads"],
"quantity": "400 g",
"packaging": null,
"packagingTags": ["en:plastic", "fr:pot-en-verre"],
"stores": ["carrefour"],
"traces": [],
"servingSize": null,
"servingQuantity": null,
"nutriScoreGrade": "e",
"novaGroup": 4,
"nutritionPer100g": {
"energyKj": 2252,
"energyKcal": 539,
"fat": 30.9,
"sugars": 56.3,
"proteins": 6.3
},
"sourceUrl": "https://world.openfoodfacts.org/product/3017620422003",
"duplicateCount": 1,
"error": null
}

Source records are community-maintained and can change. Treat the example as a shape illustration, not a permanent claim about that product.

How much does it cost to look up Open Food Facts products?

Pay-per-event pricing has a $0.005 run-start fee plus a tiered lookup-record event. At the BRONZE tier, each found or confirmed not-found record is $0.0084.

BRONZE calculation examples:

Unique barcodesBilling formula
1one run-start event + one item event
10one run-start event + ten item events
100one run-start event + one hundred item events

Your Apify pricing tier may have a different per-record rate. Duplicates beyond their first occurrence do not create another lookup record or item charge. A user-set maximum total charge stops new lookups and prevents publishing further billable rows when the remaining budget cannot cover an item; check budgetStopped in the completion log.

Getting started

  1. Open the Actor in Apify Console.
  2. Paste real barcode strings into EAN, UPC, or GTIN codes.
  3. Keep concurrency at 3 unless you have a reason to lower it.
  4. Click Start.
  5. Review the Product lookups dataset view.
  6. Export JSON, CSV, Excel, XML, or RSS, or connect the dataset to another workflow.

Catalog enrichment workflow

Run the Actor with a supplier barcode column, then join the output back to your catalog on gtin. Use status to route records:

  • found: import reviewed identity and food-specific fields;
  • not_found: send to a manual data-completion queue;
  • lookup_error: inspect the bounded diagnostic and retry later; the source may have failed, returned invalid/mismatched data, or exceeded the run's deadline.

For change monitoring, schedule the same task and compare sourceRevision or sourceLastModifiedAt with your previous dataset. The Actor reports timestamps; it does not itself store diffs or send alerts.

Use the Actor with the Apify API

Replace YOUR_TOKEN with an Apify API token.

cURL

curl -X POST \
"https://api.apify.com/v2/acts/automation-lab~ean-upc-gtin-product-lookup/runs?token=YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d '{"codes":["3017620422003","5449000000996"],"maxItems":2}'

JavaScript

import { ApifyClient } from 'apify-client';
const client = new ApifyClient({ token: process.env.APIFY_TOKEN });
const run = await client.actor('automation-lab/ean-upc-gtin-product-lookup').call({
codes: ['3017620422003', '5449000000996'],
maxItems: 2,
});
const { items } = await client.dataset(run.defaultDatasetId).listItems();
console.log(items);

Python

from apify_client import ApifyClient
client = ApifyClient("YOUR_TOKEN")
run = client.actor("automation-lab/ean-upc-gtin-product-lookup").call(
run_input={"codes": ["3017620422003", "5449000000996"], "maxItems": 2}
)
items = client.dataset(run["defaultDatasetId"]).list_items().items
print(items)

Use with MCP and AI agents

Claude Code

Add the Actor to Claude Code:

claude mcp add --transport http apify \
"https://mcp.apify.com?tools=automation-lab/ean-upc-gtin-product-lookup"

Claude Desktop, Cursor, and VS Code

Use this MCP server configuration in Claude Desktop, Cursor, or VS Code:

{
"mcpServers": {
"apify": {
"url": "https://mcp.apify.com?tools=automation-lab/ean-upc-gtin-product-lookup"
}
}
}

Example prompts:

  • “Look up these grocery GTINs and return only products containing milk allergens.”
  • “Resolve this supplier barcode batch and summarize all not-found identifiers.”
  • “Compare the Open Food Facts source revision fields in these two run datasets.”

Legality and responsible use

Open Food Facts is a collaborative database. Records may be incomplete, multilingual, outdated, or entered differently across markets. Verify important nutrition, allergen, safety, and compliance decisions against packaging or an authoritative source. This Actor normalizes public fields but does not certify their accuracy.

Use the data in accordance with Open Food Facts terms and database licensing requirements. Preserve attribution and share-alike obligations where they apply. Do not use this Actor to make unsupported medical or health claims.

Rate limits and batch timeout

Open Food Facts documents 15 product requests per minute per IP. This Actor spaces every initial attempt and retry by at least 4.5 seconds (at most 14 starts in a sliding minute). Retry-After seconds/dates apply to all queued requests. A wait over 60 seconds produces an uncharged lookup error rather than retrying earlier than requested. Other transient failures use bounded backoff, at most three attempts per identifier and a 20-second request timeout.

A normal 100-code batch takes at least about 7.5 minutes; 500 takes about 37.5 minutes, before slow responses/retries. The platform default is 3600 seconds at 256 MiB, with requests stopping 30 seconds before the earlier of that runtime bound or a caller-supplied platform timeout. This leaves roughly 22 minutes beyond normal 500-code pacing for delays; it cannot guarantee completion of every upstream retry during an outage. Remaining identifiers receive explicit, uncharged deadline-error rows rather than disappearing. Use smaller batches with lower custom timeouts. Check the diagnostics view and final counts before treating the batch as complete.

Per-run pacing cannot guarantee aggregate IP compliance when multiple simultaneous runs share an egress IP. Avoid overlapping batches. No proxy, API host migration or bulk-download route is used.

Diagnostic privacy

Failed operations send sanitized diagnostic input, exceptions and Actor/build/run IDs to our private GlitchTip service for repair. Secret fields and URL queries are removed; reports are retained for 30 days. Expected not-found results and ordinary retries are not reported. Input, results and run logs remain in your Apify account under its storage retention settings; the Actor creates no separate catalog cache. You can delete run datasets and key-value storage in Console. Do not submit secrets or personal data as barcodes. For help, open an issue from the Actor's Apify Store page.

Limits and failure behavior

  • Only standard 8, 12, 13, and 14 digit GTIN formats are accepted.
  • Invalid lengths or check digits fail the run before charging the start event.
  • At most 500 unique codes are processed per run.
  • The Actor does not search by product name, category, brand, or image.
  • The source can return products with only some fields populated.
  • Transient 429, 5xx, timeout, and network failures are retried with backoff.
  • An exhausted source failure, malformed response or mismatched identity produces an uncharged lookup_error row for diagnosis. Only explicit source absence or HTTP 404 becomes billable not_found.
  • No proxy fallback is used or needed for the public API route.

Troubleshooting

The run says the check digit is wrong. Confirm that the full printed barcode was copied, including leading zeroes. Supply codes as strings, not spreadsheet numbers.

A known product is not_found. Check the product page URL in the output and retry the exact code. Open Food Facts may not contain that regional code or may store a different package variant.

Some nutrition fields are null. The source record did not expose those values. The Actor does not infer missing nutrition.

I received lookup_error. Inspect error and the run log, then retry later.

FAQ

Does the OpenFoodFacts API require a key?

No. This Actor uses anonymous product lookup with a descriptive User-Agent. Your Apify token is still required when starting the Actor through Apify API or MCP.

Can I look up UPC codes with leading zeroes?

Yes. Enter them as strings. The output preserves the normalized submitted identifier and reports format as UPC-A.

Does the Actor download images?

No. It returns public image URLs, avoiding unnecessary transfer and storage costs.

Can I monitor product changes?

Yes. Schedule recurring runs and compare source revision or modification fields downstream. The Actor does not send alerts by itself.

Are not-found rows charged?

Yes, because they are confirmed lookup results and support validation workflows.