gasprices.aaa.com APIgasprices.aaa.com ↗
Retrieve national, state, and metro gas prices from AAA. Covers all fuel grades, historical trends, EV charging rates, and news. 12 endpoints.
No input parameters required.
curl -X GET 'https://api.parse.bot/scraper/8c9bd3db-a958-41a6-8e97-b4e58c80a4d6/get_national_average' \ -H 'X-API-Key: $PARSE_API_KEY'
Returns today's AAA national average gas price for all fuel grades (Regular, Mid-Grade, Premium, Diesel) with historical comparisons to yesterday, one week ago, one month ago, and one year ago.
No input parameters required.
{
"type": "object",
"fields": {
"date": "string, date the prices were recorded (e.g. '5/14/26')",
"prices": "object with keys Regular, Mid-Grade, Premium, Diesel each containing current, yesterday, week_ago, month_ago, year_ago prices as numbers",
"location": "string, always 'National'"
},
"sample": {
"data": {
"date": "5/14/26",
"prices": {
"Diesel": {
"current": 5.667,
"week_ago": 5.674,
"year_ago": 3.542,
"month_ago": 5.65,
"yesterday": 5.659
},
"Premium": {
"current": 5.399,
"week_ago": 5.415,
"year_ago": 4.024,
"month_ago": 4.992,
"yesterday": 5.375
},
"Regular": {
"current": 4.534,
"week_ago": 4.558,
"year_ago": 3.18,
"month_ago": 4.118,
"yesterday": 4.511
},
"Mid-Grade": {
"current": 5.025,
"week_ago": 5.044,
"year_ago": 3.672,
"month_ago": 4.627,
"yesterday": 5.005
}
},
"location": "National"
},
"status": "success"
}
}About the gasprices.aaa.com API
The AAA Gas Prices API exposes 12 endpoints covering national, state, and metro-level average fuel prices across Regular, Mid-Grade, Premium, and Diesel grades. get_national_average returns today's price alongside comparisons to yesterday, last week, last month, and last year. Other endpoints surface per-state breakdowns, metro-level rankings, price-change deltas, EV charging costs by state, and full-text AAA news articles.
Fuel Price Coverage
get_national_average returns a single-object response with a prices field containing all four fuel grades, each carrying five time-period values: current, yesterday, week_ago, month_ago, and year_ago. get_state_gas_prices returns an array of all 50 states plus DC with current prices for every grade. For a deeper look at one state, get_state_price_details takes a state_code parameter (e.g. TX) and adds highest_recorded prices with their recorded dates — useful for contextualizing current spikes against historical peaks.
Metro and Delta Endpoints
get_metro_prices_by_state and get_price_change_by_metro both accept a state_code and return arrays of named metro areas. The delta endpoints (get_price_change_by_state, get_price_change_by_metro) return computed change values — day_change, week_change, month_change, year_change — keyed by fuel type, so you can build trend indicators without doing the arithmetic yourself. get_lowest_state_prices and get_lowest_metro_prices return pre-sorted arrays by ascending regular price, ready for cheapest-fuel lookups.
EV Charging Data
get_ev_charging_prices returns a flat array of location objects with LOCATION_NAME, LOCATION_STATE, LOCATION_TYPE, ev_totalchargers, and ev_costperkwh. All fields are strings, including the numeric ones, so cast before arithmetic. Coverage is national but the granularity is state-level, not individual station.
News Articles
get_news_articles supports page and limit parameters and returns article metadata including title, date, excerpt, slug, and link, plus total_pages and total_posts for pagination control. To get full article text, pass the slug to get_news_article_detail, which returns the complete content field as HTML.
- Display a live national gas price dashboard comparing current Regular prices to last week and last year using
get_national_average. - Rank all 50 states by cheapest regular gas for a fuel-cost comparison tool using
get_lowest_state_prices. - Show week-over-week and month-over-month price deltas for each fuel grade in a specific state using
get_price_change_by_state. - Build a metro-level fuel cost finder for a given state, sorted by lowest price, using
get_lowest_metro_prices. - Surface EV versus gasoline cost comparisons by combining
ev_costperkwhfromget_ev_charging_priceswith state-level gas prices. - Alert users when a state's current price approaches its all-time high using
highest_recordeddata fromget_state_price_details. - Aggregate and display recent AAA fuel market commentary using
get_news_articleswith pagination and full content viaget_news_article_detail.
| Tier | Price | Credits/month | Rate limit |
|---|---|---|---|
| Free | $0/mo | 100 | 5 req/min |
| Hobby | $30/mo | 1,000 | 20 req/min |
| Developer | $100/mo | 5,000 | 250 req/min |
One credit = one API call regardless of which marketplace API you call. Exceeding the rate limit returns a 429 response. Authenticate with the X-API-Key header.
Does AAA publish an official developer API for gas price data?+
What does `get_state_price_details` return beyond current prices?+
get_state_price_details returns, for each fuel grade, the current price plus historical averages for yesterday, one week ago, one month ago, and one year ago. It also includes a highest_recorded object with the all-time peak price and the date it was recorded for each grade. The get_highest_recorded_prices endpoint covers the same historical peak data and additionally supports omitting state_code to return national records.Does the EV charging endpoint return individual station locations or prices?+
get_ev_charging_prices returns aggregated state-level data: location name, state, location type, total charger count (ev_totalchargers), and average cost per kWh (ev_costperkwh). Station-level data is not currently exposed. You can fork this API on Parse and revise it to add a station-level endpoint if your use case requires it.Are metro-level price change deltas available for all states?+
get_price_change_by_metro accepts any two-letter state_code and returns delta values for all metro areas AAA tracks within that state. However, not every state has the same number of tracked metros, and some smaller states may return fewer entries. Metro coverage mirrors what AAA publishes for that state — there is no configurable metro filter within the endpoint.