Refinancing your house loan can be a strategic financial move to lower your monthly payments, reduce the total interest paid over the life of the loan, or even cash out equity for other needs. This calculator helps you estimate the potential savings you could achieve by refinancing.
How the Calculator Works: The Math Behind Refinancing
The calculator uses standard mortgage payment formulas and compares your current loan scenario with a potential new one.
1. Calculating Monthly Payments
The core of the calculation is determining the monthly principal and interest (P&I) payment for both your current and potential new loans. The formula for a fixed-rate mortgage payment is:
M = P [ i(1 + i)^n ] / [ (1 + i)^n – 1]
M = Your total monthly mortgage payment
P = The principal loan amount (your current loan balance or the new loan amount)
i = Your monthly interest rate (annual rate divided by 12)
n = The total number of payments over the loan's lifetime (loan term in years multiplied by 12)
2. Estimating Current Loan Details
Using your current loan balance, remaining term (in years), and annual interest rate, the calculator first determines your current estimated monthly P&I payment.
3. Estimating New Loan Details
Similarly, it calculates the estimated monthly P&I payment for the new loan based on the current loan balance (or potentially a new amount if you're taking cash out), the new loan term (in years), and the new annual interest rate.
4. Calculating Savings
Monthly Payment Saving: This is the difference between your current estimated monthly P&I payment and the new estimated monthly P&I payment. A positive number indicates savings.
Total Interest Saving: To calculate this, we first find the total amount paid over the life of the current loan (current monthly payment * total number of payments) and the total amount paid over the life of the new loan. The difference, minus the refinance closing costs, gives you the net saving on total interest paid.
When Does Refinancing Make Sense?
Refinancing is generally beneficial when:
Interest Rates Drop: If current market rates are significantly lower than your existing rate, you can save money on interest.
You Can Shorten Your Loan Term: Refinancing to a shorter term (e.g., from 30 to 15 years) can help you pay off your mortgage faster and save substantial interest, even if the rate isn't much lower.
Your Credit Score Improves: A better credit score might qualify you for a lower interest rate than you currently have.
You Need to Consolidate Debt or Access Cash: Cash-out refinances allow you to borrow more than your current balance and receive the difference in cash, which can be used for home improvements, education, or debt consolidation.
Important Note: Always consider the closing costs associated with refinancing. These costs need to be recouped through your monthly savings to make the refinance truly worthwhile. This calculator includes an estimate for closing costs to provide a more accurate picture of your net savings.
Example Scenario:
Let's say you have:
Current Loan Balance: $250,000
Current Annual Interest Rate: 4.5%
Current Remaining Loan Term: 25 years
Potential New Annual Interest Rate: 3.8%
Potential New Loan Term: 30 years
Estimated Refinance Closing Costs: $5,000
Using these figures, the calculator will show you how much you could save per month and over the life of the loan after accounting for the closing costs.
function calculateMortgagePayment(principal, annualRate, termYears) {
var monthlyRate = annualRate / 100 / 12;
var numberOfPayments = termYears * 12;
if (monthlyRate <= 0 || numberOfPayments <= 0) {
return 0; // Avoid division by zero or invalid calculations
}
var payment = principal * (monthlyRate * Math.pow(1 + monthlyRate, numberOfPayments)) / (Math.pow(1 + monthlyRate, numberOfPayments) – 1);
return isNaN(payment) ? 0 : payment;
}
function calculateRefinance() {
var currentLoanBalance = parseFloat(document.getElementById("currentLoanBalance").value);
var currentInterestRate = parseFloat(document.getElementById("currentInterestRate").value);
var currentLoanTerm = parseFloat(document.getElementById("currentLoanTerm").value);
var newInterestRate = parseFloat(document.getElementById("newInterestRate").value);
var newLoanTerm = parseFloat(document.getElementById("newLoanTerm").value);
var refinanceClosingCosts = parseFloat(document.getElementById("refinanceClosingCosts").value);
var resultsDiv = document.getElementById("results");
var monthlyPaymentSavingDiv = document.getElementById("monthlyPaymentSaving");
var loanSavingDiv = document.getElementById("loanSaving");
// Clear previous results
monthlyPaymentSavingDiv.innerHTML = "";
loanSavingDiv.innerHTML = "";
resultsDiv.style.display = "none";
// Validate inputs
if (isNaN(currentLoanBalance) || isNaN(currentInterestRate) || isNaN(currentLoanTerm) ||
isNaN(newInterestRate) || isNaN(newLoanTerm) || isNaN(refinanceClosingCosts) ||
currentLoanBalance <= 0 || currentInterestRate < 0 || currentLoanTerm <= 0 ||
newInterestRate < 0 || newLoanTerm <= 0 || refinanceClosingCosts < 0) {
alert("Please enter valid positive numbers for all fields.");
return;
}
// Calculate current monthly P&I payment
var currentMonthlyPayment = calculateMortgagePayment(currentLoanBalance, currentInterestRate, currentLoanTerm);
// Calculate new monthly P&I payment
var newMonthlyPayment = calculateMortgagePayment(currentLoanBalance, newInterestRate, newLoanTerm);
// Calculate monthly payment saving
var monthlyPaymentSaving = currentMonthlyPayment – newMonthlyPayment;
// Calculate total interest paid for current loan
var totalInterestPaidCurrent = (currentMonthlyPayment * (currentLoanTerm * 12)) – currentLoanBalance;
// Calculate total interest paid for new loan
var totalInterestPaidNew = (newMonthlyPayment * (newLoanTerm * 12)) – currentLoanBalance;
// Calculate total loan saving
var totalLoanSaving = totalInterestPaidCurrent – totalInterestPaidNew – refinanceClosingCosts;
// Display results
monthlyPaymentSavingDiv.innerHTML = `Monthly Payment Saving: $${monthlyPaymentSaving.toFixed(2)}`;
loanSavingDiv.innerHTML = `Total Loan Saving (after closing costs): $${totalLoanSaving.toFixed(2)}`;
resultsDiv.style.display = "block";
}