Your essential tool for estimating daily calorie needs to support your health and fitness goals.
Calculate Your Daily Calorie Needs
Enter your current age in whole years.
Enter your current weight in kilograms.
Enter the feet part of your height.
Enter the inches part of your height.
Sedentary (little or no exercise)
Lightly Active (exercise 1-3 days/week)
Moderately Active (exercise 3-5 days/week)
Very Active (exercise 6-7 days/week)
Extra Active (very intense exercise daily, or physical job)
Your Estimated Daily Calorie Intake
— kcal
Basal Metabolic Rate (BMR)— kcal
Total Daily Energy Expenditure (TDEE)— kcal
Formula UsedMifflin-St Jeor
The calculator uses the Mifflin-St Jeor equation to estimate Basal Metabolic Rate (BMR), which is then multiplied by an activity factor to determine Total Daily Energy Expenditure (TDEE).
Calorie Needs vs. Activity Level
Adjusting your activity level significantly impacts daily calorie requirements.
Activity Level Multipliers
Activity Level
Multiplier
Description
Sedentary
1.2
Little to no exercise, desk job.
Lightly Active
1.375
Light exercise or sports 1-3 days/week.
Moderately Active
1.55
Moderate exercise or sports 3-5 days/week.
Very Active
1.725
Hard exercise or sports 6-7 days/week.
Extra Active
1.9
Very hard exercise or a physical job.
var canvas = document.getElementById('calorieChart');
var ctx = canvas.getContext('2d');
var chart = null;
function convertHeightToCm(feet, inches) {
var totalInches = (feet * 12) + inches;
return totalInches * 2.54;
}
function calculateCalories() {
var age = parseFloat(document.getElementById('age').value);
var weight = parseFloat(document.getElementById('weight').value);
var heightFt = parseFloat(document.getElementById('heightFt').value);
var heightIn = parseFloat(document.getElementById('heightIn').value);
var activityLevel = parseFloat(document.getElementById('activityLevel').value);
var ageError = document.getElementById('ageError');
var weightError = document.getElementById('weightError');
var heightFtError = document.getElementById('heightFtError');
var heightInError = document.getElementById('heightInError');
var activityLevelError = document.getElementById('activityLevelError');
// Reset errors
ageError.textContent = ";
weightError.textContent = ";
heightFtError.textContent = ";
heightInError.textContent = ";
activityLevelError.textContent = ";
var isValid = true;
if (isNaN(age) || age 120) {
ageError.textContent = 'Please enter a valid age between 1 and 120.';
isValid = false;
}
if (isNaN(weight) || weight 1000) {
weightError.textContent = 'Please enter a valid weight between 1 and 1000 kg.';
isValid = false;
}
if (isNaN(heightFt) || heightFt 10) {
heightFtError.textContent = 'Please enter valid feet (0-10).';
isValid = false;
}
if (isNaN(heightIn) || heightIn = 12) {
heightInError.textContent = 'Please enter valid inches (0-11).';
isValid = false;
}
if (isNaN(activityLevel)) {
activityLevelError.textContent = 'Please select an activity level.';
isValid = false;
}
if (!isValid) {
document.getElementById('totalCalories').textContent = '– kcal';
document.getElementById('bmr').textContent = '– kcal';
document.getElementById('tdee').textContent = '– kcal';
updateChart([]); // Clear chart if inputs are invalid
return;
}
var heightCm = convertHeightToCm(heightFt, heightIn);
// Mifflin-St Jeor Equation (using male version as a baseline for neutral calculation, often used)
// BMR = (10 * weight in kg) + (6.25 * height in cm) – (5 * age in years) + 5
var bmr = (10 * weight) + (6.25 * heightCm) – (5 * age) + 5;
var tdee = bmr * activityLevel;
document.getElementById('bmr').textContent = bmr.toFixed(0) + ' kcal';
document.getElementById('tdee').textContent = tdee.toFixed(0) + ' kcal';
document.getElementById('totalCalories').textContent = tdee.toFixed(0) + ' kcal';
updateChart([
{ level: 'Sedentary', value: bmr * 1.2 },
{ level: 'Lightly Active', value: bmr * 1.375 },
{ level: 'Moderately Active', value: bmr * 1.55 },
{ level: 'Very Active', value: bmr * 1.725 },
{ level: 'Extra Active', value: bmr * 1.9 }
]);
}
function updateChart(data) {
if (chart) {
chart.destroy();
}
if (data.length === 0) return;
canvas.width = 500; // Adjust canvas size as needed
canvas.height = 300;
var labels = data.map(function(item) { return item.level; });
var values = data.map(function(item) { return item.value.toFixed(0); });
chart = new Chart(ctx, {
type: 'bar',
data: {
labels: labels,
datasets: [{
label: 'Estimated Daily Calories',
data: values,
backgroundColor: 'rgba(0, 74, 153, 0.6)', // Primary color
borderColor: 'rgba(0, 74, 153, 1)',
borderWidth: 1
}]
},
options: {
responsive: true,
maintainAspectRatio: false,
scales: {
y: {
beginAtZero: true,
title: {
display: true,
text: 'Calories (kcal)'
}
}
},
plugins: {
legend: {
display: true,
position: 'top'
},
title: {
display: true,
text: 'Calorie Needs Based on Activity Level'
}
}
}
});
}
function resetCalculator() {
document.getElementById('age').value = 30;
document.getElementById('weight').value = 70;
document.getElementById('heightFt').value = 5;
document.getElementById('heightIn').value = 10;
document.getElementById('activityLevel').value = '1.55'; // Moderately Active
document.getElementById('ageError').textContent = ";
document.getElementById('weightError').textContent = ";
document.getElementById('heightFtError').textContent = ";
document.getElementById('heightInError').textContent = ";
document.getElementById('activityLevelError').textContent = ";
calculateCalories();
}
function copyResults() {
var totalCalories = document.getElementById('totalCalories').textContent;
var bmr = document.getElementById('bmr').textContent;
var tdee = document.getElementById('tdee').textContent;
var formula = document.getElementById('formulaUsed').textContent;
var resultText = "— Calorie Intake Results —\n\n";
resultText += "Estimated Daily Calorie Intake (TDEE): " + tdee + "\n";
resultText += "Basal Metabolic Rate (BMR): " + bmr + "\n";
resultText += "—————————–\n\n";
resultText += "Key Assumptions:\n";
resultText += "- Formula: " + formula + "\n";
resultText += "- Activity Level: " + document.querySelector('#activityLevel option:checked').text + "\n";
try {
navigator.clipboard.writeText(resultText).then(function() {
alert('Results copied to clipboard!');
}).catch(function(err) {
console.error('Failed to copy: ', err);
alert('Could not copy results. Please copy manually.');
});
} catch (e) {
console.error('Clipboard API not available or failed: ', e);
alert('Your browser does not support automatic copying. Please copy the text manually.');
}
}
function toggleFaq(element) {
var answer = element.nextElementSibling;
if (answer.style.display === "block") {
answer.style.display = "none";
} else {
answer.style.display = "block";
}
}
// Initial calculation on page load
window.onload = function() {
// Include Chart.js library dynamically if not present (for standalone HTML)
if (typeof Chart === 'undefined') {
var script = document.createElement('script');
script.src = 'https://cdn.jsdelivr.net/npm/chart.js';
script.onload = function() {
resetCalculator(); // Ensure reset happens after chart lib is loaded
};
document.head.appendChild(script);
} else {
resetCalculator(); // If Chart.js is already loaded (e.g., in WordPress environment)
}
};