15 Years
20 Years
25 Years
30 Years
35 Years
40 Years
Your Estimated Mortgage Affordability
$0
Maximum Loan Amount You May Qualify For
$0
Estimated Maximum Monthly Payment (PITI + HOA)
Understanding Mortgage Affordability
Determining how much house you can afford is a critical step in the home-buying process.
Mortgage affordability calculators help estimate the maximum loan amount you might qualify for,
based on your income, debts, and lender criteria. This calculator uses common lending guidelines
to provide an estimate, but actual loan approval depends on a lender's specific underwriting
process, credit score, and other factors.
Key Factors Affecting Affordability
Annual Household Income: Your gross income is the primary factor lenders consider.
Existing Monthly Debt Payments: This includes credit cards, auto loans, student loans, and any other recurring debt obligations.
Down Payment: A larger down payment reduces the loan amount needed and can improve your chances of approval.
Interest Rate: Higher interest rates mean higher monthly payments and a lower loan amount for the same monthly budget.
Loan Term: Longer loan terms result in lower monthly payments but more interest paid over time.
Property Taxes and Homeowner's Insurance: These costs, often called 'P' (Principal) and 'I' (Interest) in PITI, are included in your total housing expense.
HOA Fees: If applicable, these monthly fees add to your overall housing cost.
Debt-to-Income Ratio (DTI): Lenders use DTI to assess your ability to manage monthly payments. It's the percentage of your gross monthly income that goes towards debt obligations.
How the Calculator Works (The Math)
This calculator estimates affordability using a common lending rule: the front-end and back-end DTI ratios.
While this calculator focuses on the back-end DTI (total monthly debt obligations including proposed mortgage)
as a primary affordability driver, lenders also consider the front-end DTI (housing costs only).
The maximum monthly housing payment is typically capped by a percentage of your gross monthly income (the DTI ratio).
For instance, a 43% DTI means your total monthly debt payments (including mortgage, property taxes, insurance, HOA, plus existing debts)
should not exceed 43% of your gross monthly income.
1. Calculate Gross Monthly Income:Gross Monthly Income = Annual Household Income / 12
2. Calculate Maximum Allowable Total Monthly Debt:Maximum Total Monthly Debt = Gross Monthly Income * (Max DTI Ratio / 100)
3. Calculate Maximum Allowable Monthly Housing Payment (PITI + HOA):Max Housing Payment = Maximum Total Monthly Debt – Total Monthly Debt Payments (excluding potential mortgage)
4. Calculate Estimated Monthly Principal & Interest (P&I):Max P&I Payment = Max Housing Payment – Monthly Property Taxes – Monthly Homeowner's Insurance – Monthly HOA Fees
5. Calculate Maximum Loan Amount:
This step involves reverse-engineering the mortgage payment formula (the amortization formula) to find the loan principal (P)
given the maximum P&I payment (M), interest rate (r), and loan term (n).
The standard monthly mortgage payment formula is:
M = P [ r(1 + r)^n ] / [ (1 + r)^n – 1]
Where:
M = Maximum P&I Payment
r = Monthly interest rate (Annual Interest Rate / 12 / 100)
n = Total number of payments (Loan Term in Years * 12)
Rearranging to solve for P (Loan Principal):
P = M [ (1 + r)^n – 1] / [ r(1 + r)^n ]
Finally, the maximum loan amount you can afford is this calculated principal plus your down payment.
Maximum Loan Amount = Calculated Principal + Down Payment
Important Considerations
This calculator provides an estimate. Your actual mortgage approval amount can vary significantly based on your credit score, lender policies, loan type (e.g., FHA, VA, Conventional), and other financial circumstances.
It's recommended to get pre-approved by a mortgage lender for a precise understanding of your borrowing capacity.
Don't stretch your budget too thin. Consider your lifestyle and other financial goals when deciding on a comfortable monthly payment.
function calculateMortgageAffordability() {
var annualIncome = parseFloat(document.getElementById("annualIncome").value);
var monthlyDebt = parseFloat(document.getElementById("monthlyDebt").value);
var downPayment = parseFloat(document.getElementById("downPayment").value);
var interestRate = parseFloat(document.getElementById("interestRate").value);
var loanTerm = parseInt(document.getElementById("loanTerm").value);
var propertyTaxes = parseFloat(document.getElementById("propertyTaxes").value);
var homeInsurance = parseFloat(document.getElementById("homeInsurance").value);
var hoaFees = parseFloat(document.getElementById("hoaFees").value);
var maxDTI = parseFloat(document.getElementById("maxDTI").value);
// Input validation
if (isNaN(annualIncome) || annualIncome <= 0 ||
isNaN(monthlyDebt) || monthlyDebt < 0 ||
isNaN(downPayment) || downPayment < 0 ||
isNaN(interestRate) || interestRate <= 0 ||
isNaN(loanTerm) || loanTerm <= 0 ||
isNaN(propertyTaxes) || propertyTaxes < 0 ||
isNaN(homeInsurance) || homeInsurance < 0 ||
isNaN(hoaFees) || hoaFees < 0 ||
isNaN(maxDTI) || maxDTI 100) {
alert("Please enter valid positive numbers for all fields. DTI must be between 0 and 100.");
return;
}
// Calculations
var grossMonthlyIncome = annualIncome / 12;
var maxTotalMonthlyDebt = grossMonthlyIncome * (maxDTI / 100);
var monthlyPropertyTaxes = propertyTaxes / 12;
var monthlyHomeInsurance = homeInsurance / 12;
var maxHousingPayment = maxTotalMonthlyDebt – monthlyDebt;
// Ensure maxHousingPayment is not negative
if (maxHousingPayment < 0) {
maxHousingPayment = 0;
}
var maxMonthlyPrincipalInterest = maxHousingPayment – monthlyPropertyTaxes – monthlyHomeInsurance – hoaFees;
// Ensure maxMonthlyPrincipalInterest is not negative
if (maxMonthlyPrincipalInterest 0 && numberOfPayments > 0 && maxMonthlyPrincipalInterest > 0) {
// Formula to calculate the loan principal (P) from the monthly payment (M)
// P = M * [ (1 + r)^n – 1] / [ r(1 + r)^n ]
var numerator = Math.pow(1 + monthlyInterestRate, numberOfPayments) – 1;
var denominator = monthlyInterestRate * Math.pow(1 + monthlyInterestRate, numberOfPayments);
maxLoanAmountPrincipal = maxMonthlyPrincipalInterest * (numerator / denominator);
} else if (maxMonthlyPrincipalInterest === 0) {
maxLoanAmountPrincipal = 0; // If P&I payment allowed is zero, then loan principal is zero.
} else {
// Handle cases where rate or term is invalid, preventing calculation
// Or if monthlyInterestRate is 0 (which isn't typical for mortgages but for completeness)
// If monthlyInterestRate is 0, P = M * n
if (monthlyInterestRate === 0 && numberOfPayments > 0) {
maxLoanAmountPrincipal = maxMonthlyPrincipalInterest * numberOfPayments;
} else {
alert("Could not calculate loan amount due to invalid interest rate or loan term.");
return; // Exit if calculation is not possible
}
}
var totalMaxLoanAmount = maxLoanAmountPrincipal + downPayment;
// Display results
document.getElementById("maxLoanAmount").innerText = "$" + totalMaxLoanAmount.toFixed(0).replace(/\B(?=(\d{3})+(?!\d))/g, ",");
document.getElementById("maxMonthlyPayment").innerText = "$" + maxHousingPayment.toFixed(2).replace(/\B(?=(\d{3})+(?!\d))/g, ",");
document.getElementById("result-container").style.display = "block";
}