Asset 20 8 2
Does AI recommend your business? Run the free check →

Join 15,000 business owners, marketers and entrepreneurs. The Sunday newsletter you'll be annoyed only arrives once a week.

Article

Best Food Nutrition APIs: 9 Data Sources for Developers

Food nutrition APIs come in three kinds: database lookups by food name or barcode, text and recipe analysis that reads a typed meal or a pasted recipe, and photo recognition that identifies food in an image. I'd pick the kind that matches what your users will type, scan or snap first, then choose between open data you can host yourself and a commercial API with a company behind it.

What developers ask first about food nutrition APIs

What does a food nutrition API hand back to my code?

Ask it about a food and you get structured nutrition facts back, ready to drop into a calorie tracker, a meal planner, a recipe site or a diet app. What changes from one provider to the next is the question you're allowed to ask. A database lookup wants a food name, an ID or a barcode. A text or recipe service takes something messier, like a line a person typed or a full ingredient list, and works out what's in it. A recognition engine starts from a photo. Those are three different products, and it's worth knowing which one your screens need before you read a single docs page.

Lookup, text analysis or photo recognition: how do I tell which kind I need?

Start from the input box in your app. If people scan packets, you need barcode lookups. If they type "two eggs and a slice of toast", you need natural-language parsing, because a plain database search won't split that sentence into items for you. If you paste recipes into a recipe site, you want recipe analysis that reads the whole ingredient list in one call. Photo recognition is sold as its own product, separate from text and barcode lookup: Passio and LogMeal both market recognition engines built for app developers. Don't assume a lookup API will grow a camera feature later; plan for two providers if you need both.

Should I host open data myself or call a hosted API?

This is the fork that shapes your architecture. Open data means you can download it, load it into your own database and query it with no network hop and no outside rate limit, but you own the updates, the search and the matching. Open Food Facts is a non-profit open database of food products that anyone may re-use for any purpose. A hosted commercial API does the search, the parsing and the upkeep for you and gives you someone to contact when something breaks. The price of that convenience is dependence: your app now relies on their uptime, their terms and their roadmap. I'd host open data when the core of the app is packaged products and call a hosted API when the hard part is understanding what people type.

How many calls can I make before I hit a limit?

Every provider sets its own ceiling, and the number belongs in your design, not your launch-week surprises. USDA FoodData Central sets a default limit of 1,000 requests per hour per IP address, and its data is public domain under CC0 1.0. That ceiling is per IP, so a backend that serves every user from one server shares it across your whole audience. Look for the limit in each provider's docs, work out your peak hour (a meal planner gets busy at very different times from a recipe site), and put a cache in front of anything you call often.

Can I use the data inside a commercial app?

Read the licence before you write the integration, because this is where a quick prototype can turn into a rewrite. FatSecret's platform describes itself as free to use, with commercial use permitted for its nutrition database. Public domain data and open data that anyone may re-use sit at the relaxed end. Hosted APIs set their own terms, and those terms can cover how long you may keep responses, whether you must show where the data came from, and whether a paid tier is needed once you go live. Find those three answers in writing for every provider on your shortlist.

What if the provider changes course after I've built on it?

It happens in this category, and recently. CalorieNinjas says it's being turned down this year, with its Nutrition and Recipe APIs now living at API Ninjas. Nutritionix says its full website is temporarily offline while it upgrades, and that its database and API remain available to registered partners. Neither is a reason to avoid a provider, but both are a reason to keep every nutrition call behind one thin layer of your own code. If you ever have to switch, you change one module instead of every screen that shows a number.

The APIs and databases on my list

Edamam

Food database, nutrition analysis and recipe APIs in one place; its developer site says you can paste a recipe and get its nutrition details in under a second.

FatSecret Platform API

A global food and nutrition database served over an API to apps, websites and devices, described by its makers as the largest of its kind.

Nutritionix

Verified nutrition database and API that, by its own count, takes 250m+ queries a month from 20k+ health apps; access currently runs through registered partners.

USDA FoodData Central

The US government's food composition database, opened up through an API, with data the department places in the public domain rather than under copyright.

spoonacular

Ingredients, products, recipes and nutrition sit behind one food and recipe API, which its makers pitch as the only food API you'll ever need.

API Ninjas Nutrition API

Natural language processing pulls nutrition information out of freeform text here, with single-item lookups and branded or barcode lookups on the side.

Work with me

Want AI doing the heavy lifting in your marketing?

I build the systems that handle the boring 80 percent, so you get your week back. Done properly, with the human kept in.

Passio Nutrition AI

Food recognition paired with nutrition data, offered as both an SDK and an API for health and wellness apps under the line "Turn food into action."

LogMeal

Its Food AI Engine is a food recognition API for apps and kiosks, and the company runs a separate nutrition management platform beside it.

Open Food Facts

A non-profit open database of packaged food products, made by everyone for everyone, with an open data API for reading it from code.

Questions to settle before you write the integration

Before the plumbing questions, it helps to look at shipped products to decide which screens and inputs you need. My guide to the best calorie counter apps shows the logging side, and the meal planner apps list shows how planning tools present recipes and shopping lists. Note which input each app leans on (search, barcode, typed text or camera), because that's the kind of API you'll need to match it.

Do you make food nutrition APIs, food databases or food recognition engines? Tool makers can ask to be considered for a featured place on this list.

How do I compare two APIs on the same foods?

Build a small sample set that looks like your real traffic and run it through every API on the shortlist. Include a branded product by barcode, a raw ingredient, a typed meal with quantities in it, and a full recipe if your app takes recipes. Then check the boring things side by side: which fields come back, which units they use, how serving sizes are expressed, and what the response looks like when an item isn't found. The empty and partial results tell you more than the happy path, because they're what your support inbox will hear about.

Can I store responses, or must I call the API every time?

That's a licence question first and a performance question second. Storing results makes your app faster and keeps you under rate limits, but some terms limit how long you may keep data or what you may do with it. Edamam lists licensing of its food and recipe data alongside its APIs, which is worth asking about if you want the data on your own servers. With public domain and open data you can keep what you like; with a hosted API, find the storage clause before you design the cache.

Is it sensible to mix more than one source?

Yes, and it's often the cleanest design. Barcode scans can go to an open product database, typed meals to a text-parsing API, and photos to a recognition engine, each behind the same internal interface. The cost is consistency: two sources can describe the same food with different fields and serving sizes. Store the source and the source's own ID with every record so you can trace a number back to where it came from and refresh it later.

So what would I build on first?

I'd start with the input, not the brand. For a product-scanning app, I'd put an open database of packaged foods at the core and keep a hosted API in reserve for gaps. For a tracker where people type what they ate, I'd go straight to a text-parsing API, because writing your own parser is a project in itself. For a recipe site, I'd choose a service that analyses a whole recipe in one call. Photo recognition I'd add last, as a separate provider, once the text and barcode paths are solid. Whatever you pick, wrap it in your own module from day one; that's the decision you'll be most glad of if a provider changes its terms or moves house.

Want your tool on this list? Featured spots and reviews here are paid partnerships. Here's how to partner with me.

Published and maintained by the Lilach Bullock team, covering marketing, AI and business growth.
Your buyers are asking AI who to use. Does it say you?

See for free whether ChatGPT, Claude, Perplexity, Gemini and Google name you, and get the plan to become the answer.

Check my AI visibility →
Sundays only

Get the Sunday newsletter.

One email a week. AI experiments, marketing tactics, and the workflows Lilach is building right now in her own business.

Subscribe free

Let’s get your marketing running on AI.

Book a free 30-minute call

We figure out what you need, where AI fits in, and what working together would look like.

Book the call →

Or take the 30-second calculator

You’ll see the hours and the money quietly leaking out of your week, and the three workflows worth building first.

Take the calculator →

Or grab the free AI resource library

Prompt packs, templates, checklists, and swipe files. The exact tools I build for paying clients. Yours, free.

Get the library →
Keep reading

More from the blog.