Refinance Calculator Formula
Understand the math behind the refinance calculator. Each variable explained with a worked example.
Formulas Used
Current Monthly Payment
current_payment = current_monthly_rate > 0 ? current_balance * current_monthly_rate * pow(1 + current_monthly_rate, current_num_payments) / (pow(1 + current_monthly_rate, current_num_payments) - 1) : current_balance / current_num_paymentsNew Monthly Payment
new_payment = new_monthly_rate > 0 ? current_balance * new_monthly_rate * pow(1 + new_monthly_rate, new_num_payments) / (pow(1 + new_monthly_rate, new_num_payments) - 1) : current_balance / new_num_paymentsMonthly Savings
monthly_savings = current_payment - new_paymentCurrent Total Cost
current_total_cost = current_payment * current_num_paymentsNew Total Cost
new_total_cost = new_payment * new_num_paymentsVariables
| Variable | Description | Default |
|---|---|---|
current_balance | Current Loan Balance(USD) | 250000 |
current_rate | Current Interest Rate(%) | 7 |
current_remaining_years | Years Remaining on Current Loan(years) | 25 |
new_rate | New Interest Rate(%) | 5.5 |
new_term_years | New Loan Term(years) | 30 |
current_monthly_rate | Derived value= current_rate / 12 / 100 | calculated |
current_num_payments | Derived value= current_remaining_years * 12 | calculated |
new_monthly_rate | Derived value= new_rate / 12 / 100 | calculated |
new_num_payments | Derived value= new_term_years * 12 | calculated |
How It Works
How Refinance Savings Work
Refinancing replaces your existing mortgage with a new one, ideally at a lower interest rate. Savings come from the difference in monthly payments.
Key Factors
Compare the total cost of remaining on your current loan vs the total cost of the new loan.
Worked Example
You owe $250,000 at 7% with 25 years remaining. You can refinance at 5.5% for 30 years.
current_balance = 250000current_rate = 7current_remaining_years = 25new_rate = 5.5new_term_years = 30
- 01Current monthly payment: $250,000 at 7% for 25 years = $1,767.63
- 02New monthly payment: $250,000 at 5.5% for 30 years = $1,419.47
- 03Monthly savings: $1,767.63 - $1,419.47 = $348.16
- 04Current total remaining cost: $1,767.63 * 300 = $530,289.00
- 05New total cost: $1,419.47 * 360 = $511,009.20
Ready to run the numbers?
Open Refinance Calculator