Refinance Auto Loan Rates Calculator

Online EMI Calculator for Personal Loans

This EMI (Equated Monthly Installment) calculator helps you estimate your monthly payments for a personal loan. Understanding your EMI is crucial for budgeting and financial planning, allowing you to see the total cost of borrowing over time.

Your Loan Details

Enter loan details above to see your EMI.

function calculateEMI() { var loanAmount = parseFloat(document.getElementById("loanAmount").value); var annualInterestRate = parseFloat(document.getElementById("annualInterestRate").value); var loanTenure = parseFloat(document.getElementById("loanTenure").value); var resultDiv = document.getElementById("result"); // Validate inputs if (isNaN(loanAmount) || loanAmount <= 0) { resultDiv.innerHTML = "Please enter a valid loan amount."; return; } if (isNaN(annualInterestRate) || annualInterestRate <= 0) { resultDiv.innerHTML = "Please enter a valid annual interest rate."; return; } if (isNaN(loanTenure) || loanTenure 0) { emi = loanAmount * monthlyInterestRate * Math.pow(1 + monthlyInterestRate, loanTenureInMonths) / (Math.pow(1 + monthlyInterestRate, loanTenureInMonths) – 1); } else { // If interest rate is 0, EMI is just principal divided by months emi = loanAmount / loanTenureInMonths; } // Calculate total interest payable var totalInterestPayable = (emi * loanTenureInMonths) – loanAmount; // Calculate total payment var totalPayment = emi * loanTenureInMonths; resultDiv.innerHTML = "Your Estimated Monthly EMI: ₹ " + emi.toFixed(2) + "" + "Total Interest Payable: ₹ " + totalInterestPayable.toFixed(2) + "" + "Total Payment (Principal + Interest): ₹ " + totalPayment.toFixed(2) + ""; } .calculator-container { font-family: sans-serif; max-width: 600px; margin: 20px auto; padding: 20px; border: 1px solid #ccc; border-radius: 8px; box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1); background-color: #f9f9f9; } .calculator-container h2 { text-align: center; color: #333; margin-bottom: 20px; } .calculator-container p { color: #555; line-height: 1.6; margin-bottom: 15px; } .calculator-inputs { display: grid; grid-template-columns: 1fr; gap: 15px; margin-bottom: 25px; } .input-group { display: flex; flex-direction: column; } .input-group label { margin-bottom: 5px; font-weight: bold; color: #444; } .input-group input[type="number"], .input-group input[type="text"] { padding: 10px; border: 1px solid #ccc; border-radius: 4px; font-size: 1rem; } .calculator-inputs button { background-color: #4CAF50; color: white; padding: 12px 20px; border: none; border-radius: 4px; cursor: pointer; font-size: 1.1rem; transition: background-color 0.3s ease; justify-self: start; /* Aligns button to the start of its grid area */ } .calculator-inputs button:hover { background-color: #45a049; } .calculator-results { background-color: #eef7ee; padding: 15px; border-radius: 6px; border: 1px solid #d0e0d0; } .calculator-results h3 { color: #333; margin-top: 0; margin-bottom: 15px; } .calculator-results p { margin: 8px 0; color: #006400; font-size: 1.05rem; } .calculator-results strong { color: #004d00; }

Leave a Comment