Nutritionix API
Overview
Nutritionix gives you access to the world's largest verified nutrition database, allowing you to look up calories, macronutrients, and micronutrients for branded and restaurant foods. It supports natural language queries like "2 eggs and toast" making it easy to build calorie trackers and diet apps. An API key is required, available after registering on their developer portal.
Beginner Tip
Use the /v2/natural/nutrients endpoint with plain English food descriptions — you do not need to search for exact product names, which makes integration much faster.
Available Data
Example Response
{
"recipe": "Chicken Stir Fry",
"calories": 380,
"protein_g": 32,
"carbs_g": 28,
"fat_g": 14,
"ingredients": [
"chicken breast",
"bell pepper",
"soy sauce",
"garlic"
],
"prep_time_minutes": 20
} Field Reference
foods List of food items parsed from the natural language query. food_name Standardized name of the identified food item. nf_calories Total calorie count for the specified serving size. nf_total_fat Total fat content in grams. nf_total_carbohydrate Total carbohydrate content in grams. nf_protein Protein content in grams. Implementation Example
const url = "https://developer.nutritionix.com/";
// Replace headers or query params with the values required by this API.
const response = await fetch(url, {
headers: {
"X-API-Key": "YOUR_API_KEY"
}
});
if (!response.ok) throw new Error(`Request failed: ${response.status}`);
const data = await response.json();
console.log(data); What Can You Build?
Note: These code examples are AI-generated and unverified. Always refer to the official API documentation for accurate usage.
Common Errors & Troubleshooting
Matrix Score Breakdown
Partially tested on Apr 5, 2026
Technical Specifications
Recipes Using Nutritionix
Build something with this API. Each recipe includes step-by-step instructions and code outlines.
Similar APIs
View All →CMS.gov
The CMS.gov Provider Data API gives access to Medicare and healthcare provider quality data from the Centers for Medicare and Medicaid Services.
FoodData Central
⭐ Beginner's PickFoodData Central is the USDA's authoritative nutritional database API, giving access to detailed nutrient profiles for hundreds of thousands of foods including branded products, raw ingredients, and restaurant items.
Infermedica
Infermedica is an AI-powered health API that analyzes symptom descriptions in plain text and suggests possible conditions or next steps.
Lexigram
Lexigram is a clinical NLP API that reads medical text and identifies clinical concepts like diagnoses, medications, and procedures using standardized ontologies.
openFDA
⭐ Beginner's PickopenFDA provides free public access to FDA datasets covering drug adverse events, product recalls, medical device reports, and food safety alerts.