|
Home > Templates > Templates > Calories Excel Daily Calorie Counter
|
1) Excel Calorie Counter IntroUse the basic Calorie Counter spreadsheet to keep track of the food that you eat each day, and the nutrients that the food contains.
|
There is also an enhanced Calorie Counter workbook that contains a recipe calculator. Input all of the recipe ingredients, and Excel calculates the calories, carbs, protein, fibre and fat per serving.
After you calculate the recipe's nutrients, you can add that as an item in the workbook's food list.
| ▶ |
Warning: Use this workbook for entertainment purposes only, or in consultation your medical professional. |
| ▶ |
Food Data: Most of the food data was obtained from Health Canada, so the ingredients and calorie counts might be different where you live. Check food product labels for accurate nutrition facts. |
To get a quick demonstration of how the Microsoft Excel calorie counter works, you can watch my 1-minute video, below.
In the calorie counter workbook, the main sheet is named FoodEntry. Each day, follow the steps below, to track the calories from your daily meals and snacks..
| ▶ |
Note: In the workbook for 2 people, there are 2 FoodEntry sheets. One has green cells for data entry, and the other has orange cells for data entry. |
Each day, enter the date, and the target calories that your medial professional recommends as your daily calorie intake.

Next, select the meal type (Breakfast/Lunch/Dinner/Snack)
Then, in the next column, use the drop down list to select a food category.

In the Food Item column, click the drop down arrow, then select one of the foods from that list.

Finally, enter the number of servings that you ate, based on the single serving amount that appears in the Measure column.
After you enter a quantity, the Calories column will automatically show the total calories in your serving of the selected food item.
At the top of the worksheet, in cell F2, a formula calculates the number of calories remaining, by subtracting the total daily calorie count, from your daily intake goal.

At the end of each day, click the "Save Daily Data and Clear" button, at the top of the FoodEntry sheet.

That button runs a macro, named AddData, to save the food data, and clear the green cells.
Here's what the AddData macro does, to save the food data that you enter each day:
Here is a screen shot of stored records on the DailyRecord sheet. The dates are stored in column A, which is not shown

NOTE: In the calorie counter workbook for 2 people, there are 2 DailyRecord sheets, with colour coding.

To see the built-in list of foods and their calories, go to the FoodList sheet, where the food data table is stored.
In the basic version of the Calorie Counter workbook, there are 5 columns with food information - Category, Food Item, Measure and Calories

In the Calorie Counter with Recipe Calculator sample file, there are 9 columns with food nutritional data -- Category, Food Item, Measure, Calories, Protein, Fat, Carbs and Fibre (you can change the spelling to Fiber, if you prefer!)

While you're using the Calorie Counter workbook, you can:
There are instructions for both tasks, in the sections below
| ▶ |
For more nutrient information, try one of these websites: |
To add a new food item to the food list, follow the steps below:

| ▶ |
The food list must be sorted by Category and Food Item, or the dependent drop down list on the FoodEntry sheet will not work correctly. Continue to the next section for details. |
After you add new food items, or make changes to the existing food items, you'll need to sort the list.
In some workbooks, there is a Sort List button at the top of the FoodList sheet.
If there's no button on the FoodList sheet, go to the next section for sorting instructions.

If there's no button on the FoodList sheet, follow the steps below, to manually sort the Food list
To edit an existing item in the food list, follow the steps below:
At the end of each day, you click a button to store that day's food data on the DailyRecord sheet. On that sheet you can see a pivot table that summarizes all of your stored food data.

To see the latest data in the pivot table, follow these steps:
You can leave the pivot table as it is, or make changes to the pivot table. Here are a few changes that I like to make in my pivot tables:
You could also create more pivot tables to summarize your daily food data, in different ways. For example:
NOTE: In the workbook for 2 people, there are 2 FoodPivot sheets. One has a pivot table with green formatting, and the other has a pivot table with orange formatting.
The enhanced version of the Excel Calorie Counter has an additional feature to help with your calorie tracking -- a Recipe Calculator. Use this tool to add your own recipes to the food list, with nutrition information.
There are 3 sample recipes in the sample file, and you can add as many more as you need. Follow the steps below, to add a new recipe to the food list.
At the top of the RecipeCalc sheet:
2) Next, in the lower section, start to enter the ingredient details:

Next, you'll enter the amounts for the first ingredient. There are two amounts required:
In columns D and E, you'll enter the ingredient information from your original recipe.
For example, in the screen shot shown below, the recipe calls for 1.25 pounds (lb) of chicken.

After you select an ingredient in column C, its information from the food list appears in the grey columns at the right side of the list.
For this next step, you'll use the measurement information that appears in column H.
For example, in the screen shot shown below, the Food List has the nutrient information for 100 grams (g) of chicken

Repeat the above steps, to enter all of the remaining key ingredients, as shown below.
NOTE: You don't need to enter herbs, spices, water, or other ingredients that won't impact the calorie count or nutrition calculations.

After you enter all the ingredients, the top section shows the calorie and nutrition calculations per serving.
To add the completed recipe to the food list:

IMPORTANT: After you add a new recipe to the food list, be sure to click the SORT LIST button, at the top of the FoodList sheet. That button runs a macro to sort the list , by Category and Food Item.
The list must be sorted, or the dependent drop down list on the FoodEntry sheet will not work correctly.

After your recipes are added to the list, you can select them in the FoodEntry worksheet, where you enter your daily food choices.

Read this section if you're interested in seeing the formulas that are in the Recipe Calculator, with a few notes on how the formulas work.
The recipes that you enter might use the same measurement system that's used in the Built-in Food list (metric). Or, your recipes might use a different measurement system, such as Imperial or US.
On the sheet named Lists, there is a list of measurement units, in an Excel table.

In the Recipe Calculator, a formula in column N calculates a multiplier, in case the recipe amounts need to be converted to a different measurement system. Here is the formula in cell N9:

The Multiplier formula uses the Excel CONVERT function, to convert the recipe number, in column D, to the equivalent amount in the food list units.
For example:

In columns H:M, the grey cells show the nutrient information for the selected ingredient. These cells have formulas that use the VLOOKUP function, and the MATCH function. For example, this formula is in cell H9:
Here's how the formula works:
In columns I:M, the results of the VLOOKUP function are multiplied by the multiplier in column N.
For example, here is the formula for Calories, in cell I9:
As you add ingredients to the recipe calculator, their nutrients are included in the total row, at the top of the RecipeCalc sheet. For example, here is the formula for total calories, in cell E6:
And here's how the formula works:
Here is the Excel VBA code for the AddData macro that runs, when you click the Save Daily Data and Clear button on the FoodEntry sheet.

Here's what the AddData macro does:
Here is the VBA code for the macro that saves the daily food data.
Note: In the section below, there's a video where I show how to add code to an Excel workbook.
Sub AddData()
Dim lRow As Long
Dim lRowNew As Long
Dim wsData As Worksheet
Dim wsEntry As Worksheet
Dim rEntry As Range
Dim rInput As Range
Dim ItemCount As Long
Set wsData = wsRecord
Set wsEntry = wsInput
ItemCount = wsEntry.Range("DailyItems").Value
Set rEntry = wsEntry.Range("InputStart") _
.CurrentRegion.Offset(1, 0).Resize(ItemCount)
Set rInput = rEntry.Resize(, 4)
lRow = wsData.Cells(Rows.Count, 1) _
.End(xlUp).Row + 1
With wsEntry
If .Range("FoodDate").Value = "" Then
MsgBox "Please enter a date"
.Range("FoodDate").Activate
GoTo exitHandler
End If
rEntry.Copy
wsData.Cells(lRow, 2).PasteSpecial _
Paste:=xlPasteValues, _
Operation:=xlNone, SkipBlanks:=False, _
Transpose:=False
lRowNew = wsData.Cells(Rows.Count, 2) _
.End(xlUp).Row
wsData.Range(wsData.Cells(lRow, 1), _
wsData.Cells(lRowNew, 1)).Value _
= wsEntry.Range("FoodDate").Value
.Range("FoodDate").ClearContents
rInput.ClearContents
.Range("FoodDate").Activate
End With
wsPivot.PivotTables(1).RefreshTable
exitHandler:
Set wsData = Nothing
Set wsEntry = Nothing
Set rEntry = Nothing
Set rInput = Nothing
Exit Sub
errHandler:
MsgBox "Could not copy data to database."
GoTo exitHandler
End Sub
To see the steps for pasting a macro into a workbook, and running the macro, please watch this short video tutorial. The written instructions are on the Add Code to Excel Workbook page.
NOTE: Also, see another calorie calculator on the Calorie Burn Calculator page. It has instructions and a sample file.
Don't miss my monthly Excel newsletter! You'll get quick tips, article links, and a bit of fun. Add your email, and click Sign Up.
Next, when you get my reply, click the Confirm button. I add this step to protect you from spam!

Last updated: March 13, 2025 3:20 PM