Calculate the real interest rate

With the US 10-year yield at 5.00% and inflation at 3.7%, the real 10-year rate is about 1.25%. The real rate is the nominal rate adjusted for inflation: (1 + nominal) / (1 + inflation) - 1. Using inflation that has already happened gives an ex-post real rate.

Do it with the API

Fetch the nominal yield and inflation separately, then put them into the same calculation. The yield response has a date, while the inflation response has a period. Keep those dates with the result so the real rate has a clear reference for both its nominal rate and its inflation input.

Use GET /v1/economics/USA/yield-curve?maturity=10y for the nominal input and GET /v1/economics/USA/inflation for the inflation input. The nominal field is a percent per year, and the inflation field is a percent over the last 12 months. The script converts each percent input inside the Fisher expression, then multiplies the result by 100 to print a percentage.

  1. Get a free API key Create a free key. Narwhal uses one account and one API key across its data APIs, and REST and MCP share that key.
  2. Set the environment variable Store the key in NARWHAL_API_KEY. The script reads that variable and sends the key as Authorization: Bearer YOUR_KEY with each request to https://api.narwhalapi.com.
  3. Fetch the inputs and calculate the rate Use the Python script to request the US yield curve with maturity=10y and the US inflation rate. It reads yield_percent from the yields array and year_over_year from the inflation response, then prints the subtraction and Fisher results.
    Python, the US real 10-year rate
    import os
    import requests
    
    H = {"Authorization": f"Bearer {os.environ['NARWHAL_API_KEY']}"}
    API = "https://api.narwhalapi.com/v1/economics/USA"
    curve = requests.get(f"{API}/yield-curve", params={"maturity": "10y"}, headers=H, timeout=10).json()
    inflation = requests.get(f"{API}/inflation", headers=H, timeout=10).json()
    
    nominal = float(curve["yields"][0]["yield_percent"])        # percent a year
    cpi = float(inflation["year_over_year"])                     # percent over the last 12 months
    print(f"nominal {nominal}%  inflation {cpi}% ({inflation['period']})")
    print(f"approximate real rate  {nominal - cpi:.2f}%")
    print(f"exact (Fisher) real rate {((1 + nominal / 100) / (1 + cpi / 100) - 1) * 100:.2f}%")
  4. Keep the inflation period with the result Read the inflation period printed beside the input rates. The script uses the inflation response as its inflation input; for a forward-looking calculation, supply your own expected inflation figure in place of that historical rate.

Do it in a sheet or without code

Put the nominal yield in B1 and the year-over-year inflation rate in B2, both as numbers expressed in percent. The formula divides each input by 100 before doing the Fisher calculation, so the cell inputs must use the same units as the API fields. Keep the yield date and inflation period beside the inputs.

Fisher real rate
=(1+B1/100)/(1+B2/100)-1

Format the result as a percentage. The division produces the inflation-adjusted rate as a fraction, and percentage formatting displays that fraction as a rate. If you want a rough view, use the subtraction formula instead. With the same percent inputs, it returns the difference in percentage points directly.

Approximate real rate
=B1-B2

A sheet also lets you replace the historical inflation input with your own expectation. Keep that choice visible beside the input, since a result based on expected inflation answers a different question from a result based on inflation that has already happened.

Which option to use when

SituationBest optionWhy
A rough viewNominal minus inflationGives an approximate real rate from the two percent inputs
Precise calculations or large ratesThe Fisher formulaIncludes the cross term that the shortcut ignores
A forward viewYour own inflation expectationUses expected inflation instead of the last inflation print

The choice of inflation input determines whether the calculation looks backward or forward. You can use the Fisher formula with either historical inflation or your own expectation.

Which yield maturity should I use?

Match the yield maturity to your horizon: use 2y for short-term and 10y for long-term. The maturity parameter accepts values such as 3m, 1y, 2y, 10y and 30y. The supplied script selects 10y, so its result is a real rate based on the US 10-year yield.

If you change the maturity, keep that maturity in the description of your result. The calculation uses whichever nominal yield you select, so the horizon is part of what the resulting real rate means.

Why do the two real rate formulas differ?

The subtraction shortcut ignores the cross term in the Fisher formula. For the 23 October 2026 example, a nominal yield of 5.00% and September 2026 inflation of 3.70% give 1.30% by subtraction and 1.25% with Fisher, a gap of 0.05 percentage points. The gap is larger at higher rates.

Fisher divides the nominal growth factor by the inflation growth factor before subtracting the original amount. Subtraction takes the difference between the rates directly. Both calculations can use the same inputs, but only the Fisher calculation includes that division.

Which inflation rate should I use with an annual yield?

Use the most recent year-over-year headline inflation rate for the ex-post calculation. The API field is year_over_year. Mixing a monthly inflation rate with an annual yield gives a wrong answer because the inputs describe different periods.

Keep the inflation reference period visible even when it differs from the yield date. In the 23 October 2026 worked example, the inflation input is the September 2026 year-over-year figure. That period identifies the historical inflation used in the calculation.

Worked example: US 10-year, 23 October 2026

On 23 October 2026, the US 10-year nominal yield was 5.00%. The inflation input was 3.70% for September 2026. Start with those percent inputs, convert them to the growth factors used by Fisher, then divide the nominal factor by the inflation factor.

With the 23 October 2026 inputs, the quick calculation subtracts September 2026 inflation of 3.70% from the 5.00% nominal yield, giving 1.30%. For Fisher, the nominal growth factor is 1.0500 and the inflation growth factor is 1.0370. Their ratio is 1.01254. Subtract 1 from the unrounded ratio and express the result as a percent, displayed as 1.25%. Keep the unrounded division in the formula until the final display so the rounded intermediate ratio does not become a new input.

StepCalculation for 23 October 2026
Nominal yield5.00%
Inflation for September 20263.70%
Approximate real rate5.00% - 3.70% = 1.30%
Divide the growth factors1.0500 / 1.0370 = 1.01254
Subtract 1 and express as percent(1.05 / 1.037 - 1) × 100
Real rate rounded for display1.25%

Published .