Pro rata is a Latin term meaning "in proportion." In financial management and accounting, a pro rata calculation is used to assign an amount to a specific fraction of time. This is commonly used for insurance premiums, interest rates, service subscriptions, or salary adjustments when an employee starts mid-month.
How to Calculate Pro Rata in Excel
In Microsoft Excel, the most accurate way to calculate a pro-rated amount is by determining the daily rate and multiplying it by the number of days the service or contract was active. The basic formula is:
(Total Amount / Total Days in Period) * Number of Days Active
Excel Date Functions
Excel stores dates as serial numbers, which makes subtraction easy. If you have a start date in cell B1 and an end date in B2, the number of days between them is simply =B2-B1 (plus 1 if you want to include both the first and last day).
Practical Example
Scenario
Total Value
Total Period
Days Used
Pro Rata Result
Yearly Subscription
$1,200
365 Days
45 Days
$147.95
Monthly Rent
$2,000
31 Days
10 Days
$645.16
Mid-Month Hire
$5,000
30 Days
15 Days
$2,500.00
Using the Pro Rata Calculator
Total Amount: Enter the full value of the contract or service.
Total Days: Enter the length of the full cycle (e.g., 365 for a year, 30 for a standard month).
Dates: Select the start and end dates of the specific period you want to charge for.
The Result: The calculator provides the specific amount and the Excel-ready formula you can copy into your spreadsheet.
function calculateProRata() {
var totalAmount = parseFloat(document.getElementById('totalAmount').value);
var daysInPeriod = parseFloat(document.getElementById('daysInPeriod').value);
var startDateStr = document.getElementById('startDate').value;
var endDateStr = document.getElementById('endDate').value;
if (isNaN(totalAmount) || isNaN(daysInPeriod) || !startDateStr || !endDateStr) {
alert("Please fill in all fields with valid data.");
return;
}
var start = new Date(startDateStr);
var end = new Date(endDateStr);
// Calculate difference in milliseconds
var diffTime = end – start;
// Convert to days (adding 1 to include the end day in the calculation)
var diffDays = Math.ceil(diffTime / (1000 * 60 * 60 * 24)) + 1;
if (diffDays <= 0) {
alert("End date must be after the start date.");
return;
}
var proRataAmount = (totalAmount / daysInPeriod) * diffDays;
// Update UI
document.getElementById('result-box').style.display = 'block';
document.getElementById('finalResult').innerText = '$' + proRataAmount.toLocaleString(undefined, {minimumFractionDigits: 2, maximumFractionDigits: 2});
document.getElementById('daysCounted').innerText = diffDays;
// Excel Formula Generation
// Logic: =(TotalAmount/DaysInCycle)*(EndDate-StartDate+1)
var formula = "=(" + totalAmount + "/" + daysInPeriod + ")*(\"" + endDateStr + "\"-\"" + startDateStr + "\"+1)";
document.getElementById('excelFormula').innerText = formula;
}