Mortgage Calculator

Find out how approximately much your new home, condo or lot will cost on a monthly basis. When you're ready to purchase your property, or if you have any questions, please contact .

This mortgage calculator can be used to figure out monthly payments of a home mortgage loan, based on the home's sale price, the term of the loan desired, buyer's down payment percentage, and the loan's interest rate. This calculator factors in PMI (Private Mortgage Insurance) for loans where less than 20% is put as a down payment. Also taken into consideration are the town property taxes, and their effect on the total monthly mortgage payment.

* * @changes 1.2.0 fixed bug with number_format, clead up comments [dt, 2006-02-16] * @changes 1.1.0 initial release [dt, 2003-01-01] * * ---------------------------------------------------- * The PHP Mortgage Calculator tries to figure out a home * owners mortgage payments, and the breakdown of each monthly * payment. * * The calculator accepts: * Price (cost of home in US Dollars) * Percentage of Down Payment * Length of Mortgage * Annual Interest Rate * * Based on the four items that the user enters, we can figure * out the down payment (in US Dollars), the ammount that the * buyer needs to finance, and the monthly finance payment. * The calculator can also break down the monthly payments * so we know how much goes towards the mortgage's interest, * the mortgage's principal, the loan's Private Mortgage Insurance * (if less that 20% was used as a down payment), and an rough * estimate of the property's residential tax * */ /* --------------------------------------------------------------------- */ /* default values /* --------------------------------------------------------------------- */ $default_sale_price = 200000; $default_annual_interest_percent = 6.5; $default_year_term = 30; $default_down_percent = 10; $default_show_progress = TRUE; /* --------------------------------------------------------------------- */ /* initialize variables /* --------------------------------------------------------------------- */ $sale_price = 0; $annual_interest_percent = 0; $year_term = 0; $down_percent = 0; $this_year_interest_paid = 0; $this_year_principal_paid = 0; $form_complete = false; $show_progress = false; $monthly_payment = false; $show_progress = false; $error = false; /* --------------------------------------------------------------------- */ /* override defaults with user input /* --------------------------------------------------------------------- */ if ( isset($_GET['sale_price']) ) { $sale_price = $_GET['sale_price']; } if (isset($_GET['form_complete'])) { $sale_price = $_GET['sale_price']; $annual_interest_percent = $_GET['annual_interest_percent']; $year_term = $_GET['year_term']; $down_percent = $_GET['down_percent']; $show_progress = (isset($_GET['show_progress'])) ? $_GET['show_progress'] : false; $form_complete = $_GET['form_complete']; } ?> Sale Price of Home, Length of Motgage and Annual Interest Rate"; } if (!$error) { $month_term = $year_term * 12; $down_payment = $sale_price * ($down_percent / 100); $annual_interest_rate = $annual_interest_percent / 100; $monthly_interest_rate = $annual_interest_rate / 12; $financing_price = $sale_price - $down_payment; $monthly_factor = get_interest_factor($year_term, $monthly_interest_rate); $monthly_payment = $financing_price / $monthly_factor; } } else { if (!$sale_price) { $sale_price = $default_sale_price; } if (!$annual_interest_percent) { $annual_interest_percent = $default_annual_interest_percent; } if (!$year_term) { $year_term = $default_year_term; } if (!$down_percent) { $down_percent = $default_down_percent; } if (!$show_progress) { $show_progress = $default_show_progress; } } if ($error) { print("
" . $error . "
\n"); $form_complete = false; } $i = 0; ?>
Purchase & Financing Information
Sale Price of Home: (In Dollars)
Percentage Down: %
Length of Mortgage: years
Annual Interest Rate: %
Explain Calculations: > Show me the calculations and amortization
    Start Over"); } ?>
Mortgage Payment Information
Down Payment:
Amount Financed:
Monthly Payment:
(Principal & Interest ONLY)
  Since you are putting LESS than 20% down, you will need to pay PMI (Private Mortgage Insurance), which tends to be about $55 per month for every $100,000 financed (until you have paid off 20% of your loan). This could add to your monthly payment.
Monthly Payment:
(Principal & Interest, and PMI)
  Residential (or Property) Taxes are a little harder to figure out... In Charlotte County, the average residential tax rate is approximately $ per year for every $1,000 of your property's assessed value.

Let's say that your property's assessed value is 85% of what you actually paid for it - . This would mean that your yearly residential taxes will be around This could add to your monthly payment.
TOTAL Monthly Payment: 0) ) { echo "\$" . number_format(($monthly_payment + $pmi_per_month + $residential_monthly_tax), "2", ".", ","); } else { echo "\$" . number_format(($monthly_payment + $residential_monthly_tax), "2", ".", ","); } ?>
(including 0) ) { echo $pmi_text; } ?> residential tax)
The down payment = The price of the home multiplied by the percentage down divided by 100 (for 5% down becomes 5/100 or 0.05)

$ = $ X ( / 100)
The interest rate = The annual interest percentage divided by 100

= % / 100
The monthly factor = The result of the following formula:
The monthly interest rate = The annual interest rate divided by 12 (for the 12 months in a year)

= / 12
The month term of the loan in months = The number of years you've taken the loan out for times 12

Months = Years X 12
The montly payment is figured out using the following formula:
Monthly Payment = * ( / (1 - ((1 + )-())))

The amortization breaks down how much of your monthly payment goes towards the bank's interest, and how much goes into paying off the principal of your loan.

Amortization For Monthly Payment: $ over years

\n"; $legend .= "\t\t\n"; $legend .= "\t\t\n"; $legend .= "\t\t\n"; $legend .= "\t\t\n"; $legend .= "\t\n"; echo $legend; // Loop through and get the current month's payments for // the length of the loan while ($current_month <= $month_term) { $interest_paid = $principal * $monthly_interest_rate; $principal_paid = $monthly_payment - $interest_paid; $remaining_balance = $principal - $principal_paid; $this_year_interest_paid = $this_year_interest_paid + $interest_paid; $this_year_principal_paid = $this_year_principal_paid + $principal_paid; print("\t\n"); print("\t\t\n"); print("\t\t\n"); print("\t\t\n"); print("\t\t\n"); print("\t\n"); ($current_month % 12) ? $show_legend = FALSE : $show_legend = TRUE; if ($show_legend) { print("\t\n"); print("\t\t\n"); print("\t\n"); $total_spent_this_year = $this_year_interest_paid + $this_year_principal_paid; print("\t\n"); print("\t\t\n"); print("\t\t\n"); print("\t\n"); print("\t\n"); print("\t\t\n"); print("\t\n"); $current_year++; $this_year_interest_paid = 0; $this_year_principal_paid = 0; if (($current_month + 6) < $month_term) { echo $legend; } } $principal = $remaining_balance; $current_month++; } ?>
MonthInterest PaidPrincipal PaidRemaing Balance
" . $current_month . "\$" . number_format($interest_paid, "2", ".", ",") . "\$" . number_format($principal_paid, "2", ".", ",") . "\$" . number_format($remaining_balance, "2", ".", ",") . "
Totals for year " . $current_year . "
 \n"); print("\t\t\tYou will spend \$" . number_format($total_spent_this_year, "2", ".", ",") . " on your house in year " . $current_year . "
\n"); print("\t\t\t\$" . number_format($this_year_interest_paid, "2", ".", ",") . " will go towards INTEREST
\n"); print("\t\t\t\$" . number_format($this_year_principal_paid, "2", ".", ",") . " will go towards PRINCIPAL
\n"); print("\t\t
 
All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. * Neither the name of David Tufts nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ ?>