{
  "schemaVersion": 1,
  "slug": "effective-annual-rate-calculator",
  "category": "finance",
  "kind": "implementation",
  "independentValidation": false,
  "implementationHash": "82be3861cb21ec94297a8f644fa8a123ed7db178cd31e3aaa6a4027bc417ba2b",
  "provenance": "Generated from the calculation contract used by the published page. Publication is not external validation.",
  "sourceFiles": [
    "data/calculators/effective-annual-rate-calculator.json",
    "src/engine.js"
  ],
  "runtimeSource": "/sources/engine.txt",
  "runtimeHash": "5c888d8898afbdee36267bb9977829e1e2ac568f6677c8ee87469c139864645c",
  "scope": "The compute function records implemented equations, constants, lookup tables and custom rules. Inputs record defaults and allowed values; outputs record precision and units. Defaults are examples, not recommendations. General background references are not evidence for this specific algorithm.",
  "publishedFormula": {
    "formula": "EAR = (1 + r ÷ n)^n − 1",
    "vars": [
      [
        "r",
        "Nominal annual rate (%)"
      ],
      [
        "n",
        "Compounding periods per year"
      ],
      [
        "EAR",
        "Effective annual rate (%)"
      ]
    ],
    "note": "EAR = (1 + r ÷ n)^n − 1. Assumes the nominal annual rate compounds n times for one year; excludes fees and product-specific APY/APR rules."
  },
  "externalEvidence": {
    "reviewedAt": "2026-10-04",
    "sources": [
      {
        "name": "OpenStax — Effective annual yield",
        "url": "https://openstax.org/books/contemporary-mathematics/pages/6-4-compound-interest"
      }
    ],
    "basis": "EAR = ((1 + nominal percent / (100 × m))^m - 1) × 100.",
    "limitations": "m is the selected number of compounding periods per year; fees and taxes are excluded.",
    "implementationHash": "82be3861cb21ec94297a8f644fa8a123ed7db178cd31e3aaa6a4027bc417ba2b"
  },
  "contract": {
    "compute": "const n=Number(compounds);\nconst per = nominalRate/100/n;\nconst ear = (Math.pow(1+per,n)-1)*100;\nreturn { nominalRateOut: nominalRate, effectiveRate: ear, periodicRate: per*100, difference: ear-nominalRate, periodsPerYear: n };",
    "inputs": [
      {
        "name": "nominalRate",
        "type": "number",
        "default": 6,
        "min": 0,
        "max": 100,
        "step": 0.05,
        "requiredValue": true
      },
      {
        "name": "compounds",
        "type": "select",
        "default": 12,
        "options": [
          {
            "value": 1
          },
          {
            "value": 2
          },
          {
            "value": 4
          },
          {
            "value": 12
          },
          {
            "value": 52
          },
          {
            "value": 365
          }
        ]
      }
    ],
    "outputs": [
      {
        "name": "effectiveRate",
        "precision": 3,
        "unit": "%",
        "trimTrailingZeros": true
      },
      {
        "name": "nominalRateOut",
        "precision": 3,
        "unit": "%",
        "trimTrailingZeros": true
      },
      {
        "name": "periodicRate",
        "precision": 4,
        "unit": "%",
        "trimTrailingZeros": true
      },
      {
        "name": "difference",
        "precision": 3,
        "unit": "pp",
        "trimTrailingZeros": true
      },
      {
        "name": "periodsPerYear",
        "precision": 0,
        "unit": "",
        "trimTrailingZeros": true
      }
    ],
    "interpret": null
  }
}
