Software tools for calculating the Cost of a Healthy Diet

The software tools on this page are designed to help you convert any set of food price data into the cost per day of a healthy diet, using Excel or Stata. These calculations are now used for the Cost and Affordability of Healthy Diets (CoAHD) metric of global food security reported in FAOSTAT, and are also used to analyze variation in food access within countries as described in our collection of research results.

These tools are designed to help you compute diet costs as described in our 10-page methods brief accompanying the FAOSTAT database, with additional details on our project’s World Bank DataHub. The methods themselves are taught in a six-hour self-paced World Bank eLearning course, and explained in our publications and events shown on this website.

The software that you can download via the link below is version 6.0 of our toolkit, updated based on work with early adopters in several countries. We welcome your feedback, and any comments or suggestions that could help us improve the package for other users. You can also scroll down this page to find a tutorial video and replication files for previously published studies, with the code and data to reproduce those results.

Our technical assistance tools automatically compute least-cost healthy diets from local food price observations. Designed to be fully adaptable for integration into your data analysis protocols.

What’s inside?
Our software tools are packaged in a zipped folder (3.6 MB) with the following components:

Recommended citation:
Food Prices for Nutrition. Software tools for calculating the Cost of a Healthy Diet, Version 6.0. Published September 2023. Boston: Tufts University, available at:

Excel workbook tutorial video

Guide for collecting and analyzing your own food price data

You may wish to analyze food price data that you collect from a specific area of focus, like a region, city, or a food market. The document in this section provides guidance on how to select and/or collect your own food price data, and also discusses how to calculate the Cost of a Healthy Diet and related indicators from this data.

You can download our food price data collection and analysis guidance document here, produced in collaboration with the Food Environment Toolbox.

A data collection sheet is also available to download here, accompanying the software tools above.

Data & code to replicate published studies

Replication code & data for specific research papers

Replication folder for Schneider et al. (2022), Assessing the affordability of nutrient-adequate diets, American Journal of Agricultural Economics, e12334 [preprint].

Replication folder for Bai et al. (2022), Retail prices of nutritious food rose more in countries with higher COVID-19 case countsNature Food 3: 325–330.

Replication folder for Bai et al. (2021), Retail consumer price data reveal gaps and opportunities to monitor food systems for nutrition. Food Policy 104: e102148.

Replication folder for Bai et al. (2021), Cost and affordability of nutritious diets at retail prices: Evidence from 177 countries. Food Policy 99: e101983.

Replication folder for Schneider, K. R. (2020), Household Consumption, Individual Requirements, and the Affordability of Nutrient-Adequate Diets – An Application to Malawi. Tufts University Friedman School of Nutrition Science and Policy.

Replication folder for Masters et al. (2018), Measuring the affordability of nutritious diets in Africa: Price indexes for diet diversity and the cost of nutrient adequacy.  American J. of Agricultural Economics 100(5, October): 1285-1301.

Generic code and data for calculating least-cost nutrient adequate diets

Code and pseudodata for the calculation of the Cost of Nutrient Adequacy (CoNA), by Yan Bai (2021)

— Schneider, K. & Herforth, A. (2020). Software tools for practical application of human nutrient requirements in food-based social science research. Gates Open Research 4:179.

For the latest news, follow #FoodPricesForNutrition on LinkedIn. Some material is also on Twitter/X, Mastodon, and Bluesky.