Gas prices set a record on Wednesday for the most days in a year that the national average topped $4 a gallon.
The average regular gasoline price stood near $4.33 per gallon, about $0.02 less than a week ago but about $1.25 more than a year ago, according to AAA data.
Wednesday marked the 158th day on which prices remained above $4, according to a GasBuddy analysis, breaking the 2022 record of 157.
In California, where higher taxes and strict fuel regulations contribute to elevated prices, regular gasoline averages $6.28 per gallon, up from $4.65 a year ago.
The war in the Middle East and the closure of the Strait of Hormuz have driven gas prices to seasonal record highs.
"I think gasoline prices will remain above $4 for the next several months unless there is some resolution between the USA and Iran that results in the reopening of the Strait of Hormuz, " Andy Lipow of Lipow Oil Associates told Yahoo Finance on Tuesday.
Meanwhile, the national average for diesel stood near $6.29 per gallon on Tuesday, down from a record high of $6.52 per gallon last month. Diesel costs directly affect the prices of goods and services, given how heavily it is relied upon for farming, trucking, and deliveries.
"I thought I was going out on a limb when I predicted we would have a four-dollar handle for gas prices and a six-dollar handle for diesel prices on Election Day," said Tom Kloza, chief energy adviser at Gulf Oil. "Now it looks as though we could approach or top 2026 highs, particularly for diesel."
The Trump administration has taken measures to lower energy costs ahead of the mid-term elections. That includes an executive order allowing red-dyed diesel to be used legally in highway vehicles through the end of 2026 and a deal with Russia to release supply to the US and the world market.
Gasoline and heating oil futures, which move in lockstep with diesel, show a year-to-date surge of more than 86% and 132%, respectively, according to AlphaSpace data.

Oil prices remained elevated this week following deadly attacks in the Middle East and strikes on Ukraine's energy infrastructure, which cast doubt on the Russia-Ukraine "energy ceasefire" recently announced by President Trump.
Brent crude (BZ=F) remained near $107 per barrel, while West Texas Intermediate crude (CL=F) hovered near $95 a barrel.
Ines Ferre is a Senior Business Reporter for Yahoo Finance covering the US stock market, publicly traded companies, and commodities.
Click here for the latest stock market news and in-depth analysis, including events that move stocks
Read the latest financial and business news from Yahoo Finance
This article originally appeared on Yahoo Finance at https://finance.yahoo.com/markets/article/gas-has-now-topped-4-a-gallon-for-a-record-158-days-chart-of-the-day-100000942.html