California is home to some of the highest gas prices in the United States, according to AAA.

The national average for a gallon of regular unleaded was $3.40 as of Thursday, according to the organization’s data. In California, the average was $4.87, more than any other state.

Several factors go into what drivers pay for gas, including refining costs, taxes, distribution and marketing, and crude oil prices, according to the U.S. Energy Information Administration.

High taxes are partly to blame in California. The state has the highest gasoline taxes in the nation, according to EIA.

But there’s more to the story.

An isolated market and a special fuel blend

California requires a special blend of gasoline that reduces pollution — and costs more money. 

“California also has seen a drop of 66% in the amount of refineries in operation from where we were 40 years ago,” said Patrick De Haan, head of petroleum analysis for GasBuddy. “So there are fewer refineries producing this special blend of gasoline.” 

More from Personal Finance:
Many think pensions key to achieving American Dream
How to avoid unexpected fees with payment apps
‘Ghosting’ gets more common in the job market

California has an isolated refinery market. The special fuel blend that is consumed in California is produced by 11 major refineries within the state, according to the California Energy Commission. 

“Not many other states use the same blend of fuel, which limits California’s supply when there’s an outage, when there’s an issue at one of our refineries,” Anlleyn Venegas, a senior public affairs specialist at AAA, told CNBC.

The isolated market means that any outages will lead to volatility in prices at the pump. 

“Part of the reason why prices have been so high is that California has really restricted the ability for refineries to expand and grow,” said De Haan. “California has been rather hostile to refinery expansions or oil industry investments, trying to push them away and transition California to more electric vehicles.”

California plans to ban the sale of new gas-powered cars by 2035 as it transitions to cleaner vehicles. A quarter of new cars sold in California in 2023 were zero-emission vehicles, according to the California Energy Commission.

“The high price of gasoline does encourage more EV adoption,” De Haan said. “Americans getting hit with $5 and $6 [per] gallon prices in California is likely accelerating the shift away.” 

In 2023, California Gov. Gavin Newsom signed a new law to combat alleged price gouging at the pump. The law aims to increase transparency in the oil and gas industry and created an independent watchdog called the Division of Petroleum Market Oversight.

“There hasn’t really been much impact,” De Haan said. “But I do believe that in the months ahead, there probably will be more … talk on this subject.” 

Driving behaviors, smart shopping can cut fuel costs

Families are spending thousands of dollars on gasoline each year. In 2022, the average annual spending per consumer unit on gasoline and other fuels was $3,120, according to the Bureau of Labor Statistics. That tally was up 45.3% from 2021, as more people resumed commuting after the pandemic and fuel prices rose.

“Adopting new and improved driving behaviors can contribute to significant savings,” Venegas said.

For drivers who aren’t going electric, here are a few ways to save on gas, according to AAA:

  • Plan your route before you go
  • Don’t drive aggressively

Watch the video above to learn more about what is driving gas prices higher and what drivers can do about it.