Estimate how much house you can afford based on your income and debts.
Please enter valid positive numbers for income and interest rate.
Maximum Home Price
$0
Max Monthly Payment$0
Loan Amount$0
Est. Monthly P&I$0
Est. Monthly Tax/Ins$0
How Much House Can I Afford?
Determining your budget is the first step in the home buying process. This Home Affordability Calculator helps you estimate the maximum home price you can afford by analyzing your income, existing debts, and current mortgage interest rates. It uses the standard 28/36 rule used by many lenders to ensure you don't overstretch your finances.
Understanding the Calculation
Lenders primarily look at your Debt-to-Income (DTI) ratio to decide how much they are willing to lend. There are two types of DTI ratios considered in this calculator:
Front-End Ratio (Housing Ratio): This compares your projected monthly housing costs (mortgage principal, interest, taxes, and insurance) to your gross monthly income. Most lenders prefer this not to exceed 28%.
Back-End Ratio (Total Debt Ratio): This compares your total monthly debt obligations (including the new mortgage plus student loans, car payments, and credit cards) to your gross monthly income. A common limit is 36%.
Key Factors Affecting Affordability
Several variables impact your purchasing power:
Interest Rates: Even a small increase in interest rates can significantly increase your monthly payment, reducing the total loan amount you qualify for.
Down Payment: A larger down payment reduces the loan amount needed, lowering monthly payments and potentially allowing you to buy a more expensive home.
Monthly Debts: Reducing your existing monthly debts (like paying off a car loan) directly increases the amount available for a mortgage payment, boosting your buying power.
Why Property Taxes and Insurance Matter
Many buyers focus solely on the mortgage principal and interest, forgetting that property taxes and homeowners insurance are often bundled into the monthly payment (escrow). In high-tax areas, these costs can reduce your buying power by tens of thousands of dollars. Our calculator includes these estimates to give you a realistic "out-the-door" budget.
How to Improve Your Affordability
If the result is lower than you hoped, consider improving your credit score to qualify for lower interest rates, paying down high-interest consumer debt, or saving for a larger down payment to avoid Private Mortgage Insurance (PMI) and reduce monthly costs.
function calculateAffordability() {
var incomeInput = document.getElementById("annualIncome");
var debtsInput = document.getElementById("monthlyDebts");
var downPaymentInput = document.getElementById("downPayment");
var interestInput = document.getElementById("interestRate");
var termInput = document.getElementById("loanTerm");
var taxInput = document.getElementById("propertyTaxRate");
var insuranceInput = document.getElementById("homeInsurance");
var dtiInput = document.getElementById("dtiRatio");
var errorDiv = document.getElementById("errorMsg");
var resultDiv = document.getElementById("resultsArea");
// Get values
var annualIncome = parseFloat(incomeInput.value);
var monthlyDebts = parseFloat(debtsInput.value) || 0;
var downPayment = parseFloat(downPaymentInput.value) || 0;
var interestRate = parseFloat(interestInput.value);
var years = parseFloat(termInput.value);
var taxRateAnnual = parseFloat(taxInput.value) || 0;
var insuranceAnnual = parseFloat(insuranceInput.value) || 0;
var maxBackEndDTI = parseFloat(dtiInput.value) || 36;
// Validation
if (isNaN(annualIncome) || isNaN(interestRate) || isNaN(years) || annualIncome <= 0) {
errorDiv.style.display = "block";
resultDiv.style.display = "none";
return;
}
errorDiv.style.display = "none";
// 1. Calculate Allowable Monthly Payment based on Income and Debts
var monthlyGrossIncome = annualIncome / 12;
// Front-end ratio (typically 28% of income for housing alone)
var limitFrontEnd = monthlyGrossIncome * 0.28;
// Back-end ratio (Total debt / Income <= maxBackEndDTI%)
// Max Total Debt allowed = Income * (DTI/100)
// Max Housing allowed = Max Total Debt – Other Debts
var limitBackEnd = (monthlyGrossIncome * (maxBackEndDTI / 100)) – monthlyDebts;
// The bank takes the lower of the two limits
var maxAllowedMonthlyPayment = Math.min(limitFrontEnd, limitBackEnd);
if (maxAllowedMonthlyPayment <= 0) {
// User has too much debt
document.getElementById("maxHomePrice").innerText = "$0";
document.getElementById("maxMonthlyPay").innerText = "$0";
document.getElementById("loanAmount").innerText = "$0";
document.getElementById("monthlyPrincipal").innerText = "$0";
document.getElementById("monthlyTaxIns").innerText = "$0";
resultDiv.style.display = "block";
return;
}
// 2. Solve for Max Home Price
// MaxPayment = MortgagePayment(Loan) + MonthlyTax(Price) + MonthlyInsurance
// Loan = Price – DownPayment
// MortgagePayment = (Price – DownPayment) * K
// MonthlyTax = Price * (TaxRateAnnual / 100 / 12)
// MonthlyInsurance = InsuranceAnnual / 12
// Equation: MaxPayment = (Price – DownPayment) * K + Price * TaxFactor + InsFactor
// MaxPayment – InsFactor + (DownPayment * K) = Price * (K + TaxFactor)
// Price = (MaxPayment – InsFactor + (DownPayment * K)) / (K + TaxFactor)
var monthlyInterest = (interestRate / 100) / 12;
var numberOfPayments = years * 12;
var monthlyTaxFactor = (taxRateAnnual / 100) / 12;
var monthlyInsuranceFactor = insuranceAnnual / 12;
// Calculate Mortgage Factor K
var K = 0;
if (monthlyInterest === 0) {
K = 1 / numberOfPayments;
} else {
K = (monthlyInterest * Math.pow(1 + monthlyInterest, numberOfPayments)) / (Math.pow(1 + monthlyInterest, numberOfPayments) – 1);
}
var numerator = maxAllowedMonthlyPayment – monthlyInsuranceFactor + (downPayment * K);
var denominator = K + monthlyTaxFactor;
var maxHomePrice = numerator / denominator;
// Edge case: if maxHomePrice < downPayment (math artifact), clamp it
// Or if the math results in negative price
if (maxHomePrice < 0) maxHomePrice = 0;
// Calculate components for display
var loanAmount = Math.max(0, maxHomePrice – downPayment);
var monthlyPI = loanAmount * K;
var monthlyTax = maxHomePrice * monthlyTaxFactor;
var totalMonthly = monthlyPI + monthlyTax + monthlyInsuranceFactor;
// Formatting currency
var formatter = new Intl.NumberFormat('en-US', {
style: 'currency',
currency: 'USD',
maximumFractionDigits: 0
});
// Update DOM
document.getElementById("maxHomePrice").innerText = formatter.format(maxHomePrice);
document.getElementById("maxMonthlyPay").innerText = formatter.format(totalMonthly);
document.getElementById("loanAmount").innerText = formatter.format(loanAmount);
document.getElementById("monthlyPrincipal").innerText = formatter.format(monthlyPI);
document.getElementById("monthlyTaxIns").innerText = formatter.format(monthlyTax + monthlyInsuranceFactor);
resultDiv.style.display = "block";
}