Investing in real estate requires more than just a gut feeling; it requires a deep dive into the numbers. This Rental Property ROI Calculator is designed to help investors evaluate the potential profitability of a residential rental property. By inputting the purchase price, financing details, and operating expenses, you can determine key metrics like Cash Flow, Cap Rate, and Cash on Cash Return.
What is Net Operating Income (NOI)?
Net Operating Income (NOI) is a calculation used to analyze the profitability of income-generating real estate investments. NOI equals all revenue from the property, minus all necessary operating expenses.
Formula: NOI = Gross Income – Operating Expenses
Note: NOI is a before-tax figure and excludes principal and interest payments on loans, capital expenditures, depreciation, and amortization.
Cap Rate vs. Cash on Cash Return
Two of the most important metrics in real estate are the Capitalization Rate (Cap Rate) and Cash on Cash Return (CoC). While similar, they tell you different things about the deal.
Cap Rate: This metric indicates the rate of return that is expected to be generated on a real estate investment property based on the income the property is expected to generate. It is calculated by dividing the NOI by the property asset value (Purchase Price). It assumes you bought the property in cash, making it a great way to compare the intrinsic value of different properties regardless of financing.
Cash on Cash Return: This metric calculates the cash income earned on the cash invested in a property. It measures the annual return the investor made on the property in relation to the amount of mortgage paid during the same year. It is calculated by dividing the annual pre-tax cash flow by the total cash invested (Down Payment + Closing Costs + Rehab Costs).
How to Estimate Expenses
Accurately estimating expenses is crucial for a realistic analysis. Novice investors often overlook "phantom costs" like vacancy and maintenance.
Vacancy Rate: Always assume the property won't be rented 365 days a year. A standard conservative estimate is 5-8% (representing about 2-3 weeks of vacancy per year).
Maintenance & CapEx: Even if a house is new, things break. Setting aside 5-10% of monthly rent for repairs and Capital Expenditures (replacing a roof or HVAC eventually) ensures you aren't caught off guard.
function calculateROI() {
// 1. Get Inputs
var purchasePrice = parseFloat(document.getElementById('purchasePrice').value) || 0;
var downPayment = parseFloat(document.getElementById('downPayment').value) || 0;
var interestRate = parseFloat(document.getElementById('interestRate').value) || 0;
var loanTerm = parseFloat(document.getElementById('loanTerm').value) || 30;
var closingCosts = parseFloat(document.getElementById('closingCosts').value) || 0;
var rehabCosts = parseFloat(document.getElementById('rehabCosts').value) || 0;
var monthlyRent = parseFloat(document.getElementById('monthlyRent').value) || 0;
var annualTax = parseFloat(document.getElementById('propertyTax').value) || 0;
var annualInsurance = parseFloat(document.getElementById('insurance').value) || 0;
var monthlyHOA = parseFloat(document.getElementById('hoaFees').value) || 0;
var vacancyRate = parseFloat(document.getElementById('vacancyRate').value) || 0;
var maintenanceRate = parseFloat(document.getElementById('maintenanceRate').value) || 0;
// 2. Calculate Mortgage (Principal + Interest)
var loanAmount = purchasePrice – downPayment;
var monthlyRate = (interestRate / 100) / 12;
var numberOfPayments = loanTerm * 12;
var monthlyMortgage = 0;
if (loanAmount > 0 && interestRate > 0) {
// Standard Amortization Formula: M = P [ i(1 + i)^n ] / [ (1 + i)^n – 1]
monthlyMortgage = loanAmount * (monthlyRate * Math.pow(1 + monthlyRate, numberOfPayments)) / (Math.pow(1 + monthlyRate, numberOfPayments) – 1);
} else if (loanAmount > 0 && interestRate === 0) {
monthlyMortgage = loanAmount / numberOfPayments;
}
// 3. Calculate Operating Expenses (Monthly)
var monthlyTax = annualTax / 12;
var monthlyInsurance = annualInsurance / 12;
var monthlyVacancy = monthlyRent * (vacancyRate / 100);
var monthlyMaintenance = monthlyRent * (maintenanceRate / 100);
var totalMonthlyOpEx = monthlyTax + monthlyInsurance + monthlyHOA + monthlyVacancy + monthlyMaintenance;
// 4. Calculate Net Operating Income (NOI) – Monthly & Annual
var monthlyNOI = monthlyRent – totalMonthlyOpEx;
var annualNOI = monthlyNOI * 12;
// 5. Calculate Cash Flow
var monthlyCashFlow = monthlyNOI – monthlyMortgage;
var annualCashFlow = monthlyCashFlow * 12;
// 6. Calculate Metrics
// Total Cash Invested
var totalCashInvested = downPayment + closingCosts + rehabCosts;
// Cap Rate = (Annual NOI / Purchase Price) * 100
var capRate = 0;
if (purchasePrice > 0) {
capRate = (annualNOI / purchasePrice) * 100;
}
// Cash on Cash Return = (Annual Cash Flow / Total Cash Invested) * 100
var cocReturn = 0;
if (totalCashInvested > 0) {
cocReturn = (annualCashFlow / totalCashInvested) * 100;
}
// 7. Update DOM
document.getElementById('resultsArea').style.display = 'block';
// Helper for currency
var formatCurrency = new Intl.NumberFormat('en-US', {
style: 'currency',
currency: 'USD',
minimumFractionDigits: 2
});
document.getElementById('resNOI').innerText = formatCurrency.format(monthlyNOI) + " / mo";
document.getElementById('resMortgage').innerText = formatCurrency.format(monthlyMortgage) + " / mo";
var cashFlowEl = document.getElementById('resCashFlow');
cashFlowEl.innerText = formatCurrency.format(monthlyCashFlow) + " / mo";
if(monthlyCashFlow >= 0) {
cashFlowEl.className = "result-value value-positive";
} else {
cashFlowEl.className = "result-value value-negative";
}
document.getElementById('resCapRate').innerText = capRate.toFixed(2) + "%";
var cocEl = document.getElementById('resCoC');
cocEl.innerText = cocReturn.toFixed(2) + "%";
if(cocReturn >= 0) {
cocEl.className = "result-value value-positive";
} else {
cocEl.className = "result-value value-negative";
}
}