Pre-tax monthly income including salary, bonuses, etc.
2. Monthly Debt Payments
Your Debt-to-Income Ratio
0%
Total Monthly Income: $0
Total Monthly Debt: $0
What is a Debt-to-Income (DTI) Ratio?
Your Debt-to-Income (DTI) ratio is a personal finance measure that compares your total monthly debt payments to your gross monthly income. It is one of the most critical metrics lenders use to assess your creditworthiness and ability to repay a new loan, such as a mortgage or personal loan.
A lower DTI ratio demonstrates to lenders that you have a good balance between debt and income. Conversely, a high DTI suggests you may be over-leveraged and risky to lend to.
How DTI Affects Mortgage Approval
When applying for a home loan, lenders typically look at two types of DTI ratios:
Front-End Ratio: The percentage of your income that goes toward housing costs (mortgage principal, interest, taxes, and insurance).
Back-End Ratio: The percentage of income that goes toward all recurring debt payments, including housing, credit cards, student loans, and car payments. This is the number calculated above.
What is a Good DTI Ratio?
While requirements vary by lender and loan type, here are the general guidelines:
35% or less: Excellent. You are viewed as a safe borrower with manageable debt.
36% to 43%: Good/Acceptable. You can likely get approved, though you may not qualify for the absolute best interest rates.
44% to 49%: Risky. You may face difficulties getting approved for a conventional mortgage. FHA loans might still be an option.
50% or higher: High Risk. Most lenders will decline a mortgage application unless there are significant compensating factors.
How to Lower Your DTI Ratio
If your calculation shows a high percentage, consider these strategies before applying for a loan:
Pay off high-interest debt: Focus on eliminating credit card balances or small loans to reduce your total monthly obligations.
Increase your income: Look for opportunities to increase your gross monthly income through raises, side hustles, or overtime.
Avoid new debt: Do not open new credit lines or finance large purchases like a car while preparing to apply for a mortgage.
function calculateDTI() {
// 1. Get Input Values
var grossIncome = parseFloat(document.getElementById('dtiGrossIncome').value);
var rentMortgage = parseFloat(document.getElementById('dtiRentMortgage').value);
var carLoan = parseFloat(document.getElementById('dtiCarLoan').value);
var studentLoan = parseFloat(document.getElementById('dtiStudentLoan').value);
var creditCards = parseFloat(document.getElementById('dtiCreditCards').value);
var otherDebt = parseFloat(document.getElementById('dtiOtherDebt').value);
// 2. Validate Inputs
if (isNaN(grossIncome) || grossIncome <= 0) {
alert("Please enter a valid Gross Monthly Income greater than zero.");
return;
}
// Treat empty fields as 0
rentMortgage = isNaN(rentMortgage) ? 0 : rentMortgage;
carLoan = isNaN(carLoan) ? 0 : carLoan;
studentLoan = isNaN(studentLoan) ? 0 : studentLoan;
creditCards = isNaN(creditCards) ? 0 : creditCards;
otherDebt = isNaN(otherDebt) ? 0 : otherDebt;
// 3. Calculate Totals
var totalMonthlyDebt = rentMortgage + carLoan + studentLoan + creditCards + otherDebt;
var dtiRatio = (totalMonthlyDebt / grossIncome) * 100;
// Round to 2 decimal places
dtiRatio = Math.round(dtiRatio * 100) / 100;
// 4. Update UI
var resultBox = document.getElementById('dti-result-box');
var scoreDisplay = document.getElementById('dti-score-display');
var verdict = document.getElementById('dti-verdict');
var barFill = document.getElementById('dti-bar-fill');
var resultIncome = document.getElementById('result-income');
var resultDebt = document.getElementById('result-debt');
var resultMessage = document.getElementById('result-message');
resultBox.style.display = "block";
scoreDisplay.innerHTML = dtiRatio + "%";
resultIncome.innerHTML = grossIncome.toLocaleString('en-US', {minimumFractionDigits: 2, maximumFractionDigits: 2});
resultDebt.innerHTML = totalMonthlyDebt.toLocaleString('en-US', {minimumFractionDigits: 2, maximumFractionDigits: 2});
// 5. Determine Logic & Styles based on DTI
var color = "";
var text = "";
var message = "";
if (dtiRatio <= 35) {
color = "#2ecc71"; // Green
text = "Excellent";
verdict.className = "dti-verdict dti-status-good";
message = "Your DTI is in the excellent range. Lenders view you as a low-risk borrower.";
} else if (dtiRatio 100 ? 100 : dtiRatio;
barFill.style.width = barWidth + "%";
barFill.style.backgroundColor = color;
// Scroll to result
resultBox.scrollIntoView({behavior: "smooth"});
}