ERA Calculator Formula

Understand the math behind the era calculator. Each variable explained with a worked example.

Formulas Used

ERA

era = round(earned_runs / innings_pitched * 9 * 100) / 100

Earned Runs per Inning

runs_per_inning = round(earned_runs / innings_pitched * 1000) / 1000

Earned Runs per 9 Innings

per_game_runs = round(earned_runs / innings_pitched * 9 * 10) / 10

Innings Pitched

innings_display = innings_pitched

Variables

VariableDescriptionDefault
earned_runsEarned Runs30
innings_pitchedInnings Pitched100

How It Works

How ERA Is Calculated

Formula

ERA = (Earned Runs / Innings Pitched) x 9

ERA normalizes to a 9-inning game so you can compare pitchers with different workloads.

Benchmarks

  • Below 3.00: Excellent (ace-level)
  • 3.00-3.50: Very good
  • 3.50-4.00: Above average
  • 4.00-4.50: Average
  • Above 5.00: Below average
  • Worked Example

    A pitcher allowed 30 earned runs in 100 innings.

    earned_runs = 30innings_pitched = 100
    1. 01ERA = (30 / 100) * 9 = 0.30 * 9 = 2.70
    2. 02This is an excellent ERA

    Frequently Asked Questions

    What is the difference between earned and unearned runs?

    Earned runs are scored without the benefit of an error or passed ball. Unearned runs result from defensive mistakes and do not count in ERA.

    What is a good ERA?

    In modern baseball, an ERA below 3.50 is very good for starters. Relief pitchers often have lower ERAs due to shorter appearances.

    How do thirds of innings work?

    In baseball notation, 6.1 innings means 6 and one-third innings. For ERA calculation, use 6.333. Similarly, 6.2 = 6.667.

    Learn More

    Guide

    How to Calculate Velocity and Acceleration

    Learn how to calculate velocity and acceleration step by step. Covers average and instantaneous velocity, uniform acceleration, kinematic equations, and worked examples.

    Ready to run the numbers?

    Open ERA Calculator