Gas vs Electric Cost Calculator: What It Costs to Drive in Every State

Two vehicles, every state's fuel and electricity price

Pick vehicles from the EPA ratings or type a consumption, then see what a year of driving costs where you live and in every other state.

Every state, ranked by what B saves

Fuel and electricity prices do not move together, so the same two vehicles compare differently from state to state.

State A a year B a year B saves

Consumption is the EPA rating; prices are the latest EIA weekly pump price for the state (its own series, else its region) and the latest monthly residential electricity price. Real costs vary with driving, weather, charging losses and local rates. Sources: EPA (fueleconomy.gov) and the U.S. Energy Information Administration (EIA), public domain.

How it works

EPA consumption, EIA prices, your miles

Each vehicle's energy use comes from its EPA rating; each state's price from the U.S. Energy Information Administration. The calculator multiplies the two for the miles you drive.

Weekly pump prices

Regular, midgrade and premium gasoline and diesel from EIA's weekly retail survey: the state's own average where EIA publishes one, else its PADD region.

Monthly electricity rates

The state's average residential price per kWh from EIA's Electric Power Monthly: the cost of charging at home.

EPA ratings for real vehicles

Pick any rated car to use its city and highway figures; an EV's MPGe becomes kWh per 100 miles at EPA's 33.7 kWh a gallon.

Frequently asked questions

In most states, at home electricity rates: an EV using 30 kWh per 100 miles costs a few dollars per 100 miles, a 30 MPG car the price of 3.3 gallons. The gap depends on the state, because gas and electricity prices do not move together. The table above ranks every state at today's prices.
From the U.S. Energy Information Administration: weekly retail regular, midgrade and premium gasoline and diesel for the state (or its region where EIA publishes no state series) and the latest monthly residential electricity price for the state.
EPA counts 33.7 kWh as one gallon of gasoline, so kWh per 100 miles is 3,370 divided by MPGe. EPA measures electric use at the wall, so its figures include charging losses.
No. Electricity is priced at the state's average residential rate, the cost of charging at home. Public fast charging usually costs several times more per kWh.
EIA publishes weekly state averages for a handful of states. Every other state takes its Petroleum Administration for Defense District (PADD) region, the closest weekly figure EIA publishes.

Related tools: VIN decoder & check, EV transition advisor and the model-year scorecard.

Need energy costs in your app?

The same EIA prices are an API endpoint and an MCP tool, next to every car's EPA figures.

  • GET /v1/energy-prices?state=: weekly fuel and monthly electricity prices
  • GET /v1/cars/{uuid}: EPA city, highway and combined MPG or MPGe
  • MCP energy_prices: an annual cost for any mpg
  • Free plan includes 100 API calls a month, no card required

Need more calls? See pricing.

# This week's prices for Texas
GET /v1/energy-prices?state=TX
# A car's EPA consumption
GET /v1/cars/{uuid}