How to Calculate Apy

APY Calculator

Calculate your Annual Percentage Yield with compound interest

Daily (365/year) Weekly (52/year) Semi-Monthly (24/year) Monthly (12/year) Quarterly (4/year) Semi-Annually (2/year) Annually (1/year)
Your Effective Annual Percentage Yield (APY)
0.00%

How to Calculate APY

Annual Percentage Yield (APY) represents the real rate of return earned on an investment or paid on a deposit, taking into account the effect of compounding interest. Unlike a simple nominal interest rate, APY accounts for the fact that you earn interest on your interest throughout the year.

The APY Formula

APY = (1 + r/n)n – 1

Where:

  • r = The nominal annual interest rate (as a decimal).
  • n = The number of compounding periods per year.

APY vs. APR: What's the Difference?

The primary difference between APY and APR (Annual Percentage Rate) is compounding. APR reflects the simple interest rate over a year, which is commonly used for loans and credit cards. APY, however, reflects the total interest you will actually receive or pay when compounding is applied. If you are a saver, you want a high APY. If you are a borrower, you want to compare the APY to understand the true cost of the debt.

Example Calculation

Imagine you have a savings account with a 5% nominal interest rate that compounds monthly.

  1. Convert the rate to decimal: 0.05
  2. Identify periods: 12 (monthly)
  3. Apply formula: (1 + 0.05/12)12 – 1
  4. Result: (1.004167)12 – 1 = 0.05116 or 5.116% APY
function calculateAPY() { var nominalInput = document.getElementById('nominalRate').value; var n = parseFloat(document.getElementById('compoundingPeriods').value); if (nominalInput === "" || isNaN(nominalInput)) { alert("Please enter a valid nominal interest rate."); return; } var r = parseFloat(nominalInput) / 100; // Formula: APY = (1 + r/n)^n – 1 var apy = Math.pow((1 + (r / n)), n) – 1; var apyPercentage = (apy * 100).toFixed(4); var resultArea = document.getElementById('resultArea'); var apyDisplay = document.getElementById('apyDisplay'); var differenceNote = document.getElementById('differenceNote'); apyDisplay.innerText = apyPercentage + "%"; var diff = (apyPercentage – (r * 100)).toFixed(4); differenceNote.innerText = "Compounding adds " + diff + "% to your base nominal rate per year."; resultArea.style.display = "block"; }

Leave a Comment