Calculate your maximum home price based on income, debts, and current interest rates.
Total income before taxes.
Credit cards, student loans, car payments.
30 Years
15 Years
20 Years
10 Years
Annual tax as % of home price.
Annual insurance as % of home price.
Maximum Home Price
–
Estimated Monthly Breakdown
Principal & Interest:–
Property Taxes:–
Homeowners Insurance:–
Total Monthly Payment (PITI):–
Understanding Home Affordability
Determine exactly how much house you can afford is a critical first step in the home buying process. This calculator uses the standard debt-to-income (DTI) ratios utilized by most mortgage lenders to estimate your purchasing power.
The 28/36 Rule: Most financial advisors and lenders suggest that you spend no more than 28% of your gross monthly income on housing expenses, and no more than 36% on total debt (including housing).
Key Factors Affecting Affordability
Gross Annual Income: Your total income before taxes is the baseline for how much a bank will lend you.
Monthly Debts: Existing obligations like student loans, car payments, and credit card minimums reduce the amount of income available for a mortgage. Lowering your debt increases your buying power.
Down Payment: A larger down payment reduces the loan amount, leading to lower monthly payments and potentially a higher maximum home price.
Interest Rate: Even a small difference in interest rates can significantly impact your monthly payment and total purchasing power.
What is Included in PITI?
When lenders calculate your ability to pay, they look at PITI:
Principal: The portion of your payment that pays down the loan balance.
Interest: The cost of borrowing the money.
Taxes: Property taxes charged by your local municipality, usually bundled into your monthly payment.
Insurance: Homeowners insurance to protect the property against damage.
How to Increase Your Home Buying Budget
If the results above are lower than expected, consider these strategies: pay down high-interest consumer debt to improve your DTI ratio, save for a larger down payment to reduce the loan principal, or improve your credit score to qualify for a lower interest rate.
function calculateAffordability() {
// 1. Get Inputs
var annualIncome = parseFloat(document.getElementById('annualIncome').value);
var monthlyDebts = parseFloat(document.getElementById('monthlyDebts').value);
var downPayment = parseFloat(document.getElementById('downPayment').value);
var interestRate = parseFloat(document.getElementById('interestRate').value);
var loanTermYears = parseFloat(document.getElementById('loanTerm').value);
var propertyTaxRate = parseFloat(document.getElementById('propertyTaxRate').value);
var insuranceRate = parseFloat(document.getElementById('insuranceRate').value);
// Validation
if (isNaN(annualIncome) || annualIncome <= 0) {
alert("Please enter a valid annual income.");
return;
}
if (isNaN(monthlyDebts)) monthlyDebts = 0;
if (isNaN(downPayment)) downPayment = 0;
if (isNaN(interestRate) || interestRate <= 0) {
alert("Please enter a valid interest rate.");
return;
}
if (isNaN(propertyTaxRate)) propertyTaxRate = 0;
if (isNaN(insuranceRate)) insuranceRate = 0;
// 2. Calculate Monthly Income limits (The 28/36 Rule)
var monthlyGrossIncome = annualIncome / 12;
// Front-end Ratio: Housing costs should not exceed 28% of gross income
var maxPaymentFrontEnd = monthlyGrossIncome * 0.28;
// Back-end Ratio: Total debt (housing + existing debt) should not exceed 36% of gross income
var maxPaymentBackEnd = (monthlyGrossIncome * 0.36) – monthlyDebts;
// The lender will typically take the lower of the two limits
var maxAffordableMonthlyPayment = Math.min(maxPaymentFrontEnd, maxPaymentBackEnd);
var limitingFactor = (maxPaymentFrontEnd < maxPaymentBackEnd) ? "Limited by 28% Front-End Ratio (Income)" : "Limited by 36% Back-End Ratio (Debts)";
// Edge case: if debts are too high
if (maxAffordableMonthlyPayment <= 0) {
document.getElementById('resultsArea').style.display = 'block';
document.getElementById('maxHomePrice').innerHTML = "$0";
document.getElementById('qualificationMethod').innerHTML = "Debts are too high relative to income.";
document.getElementById('resPrincipalInterest').innerHTML = "$0";
document.getElementById('resTaxes').innerHTML = "$0";
document.getElementById('resInsurance').innerHTML = "$0";
document.getElementById('resTotalMonthly').innerHTML = "$0";
return;
}
// 3. Reverse Calculate Home Price
// PITI = MortgagePayment + MonthlyTax + MonthlyInsurance
// MortgagePayment = (Price – Down) * MFactor
// MonthlyTax = Price * (TaxRate/100 / 12)
// MonthlyInsurance = Price * (InsRate/100 / 12)
// var P = Home Price
// var D = Down Payment
// var M = Max Affordable Monthly Payment (PITI)
// Calculate Mortgage Factor (payment per dollar borrowed)
var r = interestRate / 100 / 12;
var n = loanTermYears * 12;
var mortgageFactor = (r * Math.pow(1 + r, n)) / (Math.pow(1 + r, n) – 1);
var taxFactor = (propertyTaxRate / 100) / 12;
var insuranceFactor = (insuranceRate / 100) / 12;
// Formula derived:
// M = (P – D) * mortgageFactor + P * taxFactor + P * insuranceFactor
// M = P * mortgageFactor – D * mortgageFactor + P * taxFactor + P * insuranceFactor
// M + D * mortgageFactor = P * (mortgageFactor + taxFactor + insuranceFactor)
// P = (M + D * mortgageFactor) / (mortgageFactor + taxFactor + insuranceFactor)
var numerator = maxAffordableMonthlyPayment + (downPayment * mortgageFactor);
var denominator = mortgageFactor + taxFactor + insuranceFactor;
var maxHomePrice = numerator / denominator;
// Ensure max price isn't less than down payment (unlikely but possible mathematically)
if (maxHomePrice < downPayment) {
maxHomePrice = downPayment;
}
// 4. Calculate Breakdown values based on the solved Home Price
var loanAmount = maxHomePrice – downPayment;
if(loanAmount < 0) loanAmount = 0;
var monthlyPrincipalInterest = loanAmount * mortgageFactor;
var monthlyTaxes = maxHomePrice * taxFactor;
var monthlyInsurance = maxHomePrice * insuranceFactor;
var totalMonthly = monthlyPrincipalInterest + monthlyTaxes + monthlyInsurance;
// 5. Formatting
var formatter = new Intl.NumberFormat('en-US', {
style: 'currency',
currency: 'USD',
maximumFractionDigits: 0
});
// 6. Display Results
document.getElementById('resultsArea').style.display = 'block';
document.getElementById('maxHomePrice').innerHTML = formatter.format(maxHomePrice);
document.getElementById('qualificationMethod').innerHTML = limitingFactor;
document.getElementById('resPrincipalInterest').innerHTML = formatter.format(monthlyPrincipalInterest);
document.getElementById('resTaxes').innerHTML = formatter.format(monthlyTaxes);
document.getElementById('resInsurance').innerHTML = formatter.format(monthlyInsurance);
document.getElementById('resTotalMonthly').innerHTML = formatter.format(totalMonthly);
}