The price of gas, a necessity for most Americans, tends to be somewhat unpredictable. The common, often erratic, fluctuations are due to basic supply and demand factors, but the price of gas also changes with the seasons, after natural disasters, and due to other events in the United States or around the world. The average price of gas also varies widely by state.

24/7 Wall St. reviewed the latest recorded price of gasoline in all 50 states from the American Petroleum Institute. As of March 20, the average price of one gallon of regular gasoline was $3.07 in Hawaii, the highest of all states. In South Carolina, gas cost $2.01 per gallon, the lowest of all states.

12. Michigan
> Price per gallon: $2.36
> State tax per gallon: $0.40 (5th highest)
> Annual miles traveled per driver: 13,772 (19th lowest)
> Cost of living: 5.9% lower than nation

The price of gasoline is a daily concern for most people living in the United States. Of Americans 16 and older, 87.5% drive at least occasionally. The average driver spends 47.1 minutes driving every day, according to a 2015 survey published by the AAA Foundation.

If gas prices are lower than expected in a given year, the volume of summer travel plans almost always goes up. Similarly, residents of states where gas prices are lower than average tend to drive more. By contrast, most drivers in the states with above-average gas prices report lower-than-average annual vehicle miles travelled.

Taxes and fees account for a large share of the cost of gasoline regardless of where the fuel is purchased. The federal government charges 18.4 cents on every gallon purchased in the country. Taxes and fees make up as little as 4.4% of the price per gallon in Alaska, and as much as 23.4% of the price per gallon in Pennsylvania.

To identify the states with the highest gasoline prices, 24/7 Wall St. reviewed statewide average prices per gallon of regular gasoline on March 20 from the American Automobile Association’s Daily Fuel Gauge Report. Total state motor fuel taxes and fees as of January 2017 come from the American Petroleum Institute. Annual vehicle miles traveled per licensee were calculated using data from the Federal Highway Administration’s 2015 Highway Statistics report. Regional parity data from the Bureau of Economic Analysis were used as a proxy for cost of living.

These are the states with the highest and lowest gas prices.

Click here to see the states with the highest and lowest gas prices.