The Google Fit APIs, including the Google Fit REST API, will be deprecated in 2026. As of May 1, 2024, developers cannot sign up to use these APIs.
For instructions on which API or platform to migrate to, visit the Health Connect migration guide. For a comparison of Health Connect with the Google Fit APIs and the Fitbit Web APIs, visit the Health Connect comparison guide.
Learn more about Health Connect and how to integrate with the API.
Nutrition data types
Stay organized with collections
Save and categorize content based on your preferences.
Page Summary
-
Nutrition data includes information about hydration and food consumption.
-
Hydration data points represent the volume of water consumed in a single drink.
-
Nutrition data points detail nutrients consumed as part of a meal or food item, requiring a nutrients field and either a meal type or food item field.
-
Both hydration and nutrition data types have defined names and fields for use with REST and Android interfaces.
-
Specific fields like
volumefor hydration andmeal type,food item, andnutrientsfor nutrition are detailed with their formats and units.
Data types for nutrition data.
Hydration
Each data point represents how much water a user drank in a single drink.
REST
com.google.hydrationfloat—liters)
Android
com.google.hydrationTYPE_HYDRATIONfloat—liters)
Nutrition
Each data point represents what nutrients were consumed as part of a meal or a food item. The data point contains several fields. The nutrients field is required. And either one, or both, of the meal type and food item fields are required.
REST
com.google.nutritionint—enum) (optional field)
"intVal": 1 // Unknown
"intVal": 2 // Breakfast
"intVal": 3 // Lunch
"intVal": 4 // Dinner
"intVal": 5 // Snack
string—n/a)
Map<String>—calories/grams)
"key": "calories" // Calories in kcal "key": "fat.total" // Total fat in grams "key": "fat.saturated" // Saturated fat in grams "key": "fat.unsaturated" // Unsaturated fat in grams "key": "fat.polyunsaturated" // Polyunsaturated fat in grams "key": "fat.monounsaturated" // Monounsaturated fat in grams "key": "fat.trans" // Trans fat in grams "key": "cholesterol" // Cholesterol in milligrams "key": "sodium" // Sodium in milligrams "key": "potassium" // Potassium in milligrams "key": "carbs.total" // Total carbohydrates in grams "key": "dietary_fiber" // Dietary fiber in grams "key": "sugar" // Amount of sugar in grams "key": "protein" // Protein amount in grams
Android
com.google.nutritionTYPE_NUTRITIONint—enum) (optional field)
MEAL_TYPE_UNKNOWN // Unknown
MEAL_TYPE_BREAKFAST // Breakfast
MEAL_TYPE_LUNCH // Lunch
MEAL_TYPE_DINNER // Dinner
MEAL_TYPE_SNACK // Snack
string—free-form text)
Map<String>—kilocalories/grams/milligrams)
NUTRIENT_CALORIES // Calories in kcal NUTRIENT_TOTAL_FAT // Total fat in grams NUTRIENT_SATURATED_FAT // Saturated fat in grams NUTRIENT_UNSATURATED_FAT // Unsaturated fat in grams NUTRIENT_POLYUNSATURATED_FAT // Polyunsaturated fat in grams NUTRIENT_MONOUNSATURATED_FAT // Monounsaturated fat in grams NUTRIENT_TRANS_FAT // Trans fat in grams NUTRIENT_CHOLESTEROL // Cholesterol in milligrams NUTRIENT_SODIUM // Sodium in milligrams NUTRIENT_POTASSIUM // Potassium in milligrams NUTRIENT_TOTAL_CARBS // Total carbohydrates in grams NUTRIENT_DIETARY_FIBER // Dietary fiber in grams NUTRIENT_SUGAR // Amount of sugar in grams NUTRIENT_PROTEIN // Protein amount in grams
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025年08月28日 UTC.