# Official Fuel Prices — France, Spain, Italy & Western Australia (`sste/official-fuel-prices`) Actor

Live fuel prices from official government open data (France, Spain, Italy, Western Australia) in one normalized schema. Search by radius, postal code, city, brand and fuel type; sort by price or distance. No API key.

- **URL**: https://apify.com/sste/official-fuel-prices.md
- **Developed by:** [SSTE](https://apify.com/sste) (community)
- **Categories:** Travel, E-commerce, Agents
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.50 / 1,000 price records

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Fuel Prices API — France, Spain, Italy & Western Australia (official data)

**Official Fuel Prices** returns current **petrol (gasoline), diesel, LPG, CNG and hydrogen prices for ~46,000 fuel stations** in **France, Spain, Italy and Western Australia**, taken directly from each **government's open data**, in **one consistent JSON schema**. Find the **cheapest or nearest stations** around coordinates, by postal code, city or brand — from the Apify Console, the REST API, Python/JavaScript, or any **MCP-compatible AI agent**.

No key for the government sources, no scraping of private sites, and every row carries its official source and licence.

| Country | Stations | Freshness | Official source |
|---|---|---|---|
| 🇫🇷 France | ~9,800 | every ~10 min | Ministère de l'Économie (DGCCRF) |
| 🇪🇸 Spain | ~11,500 | every ~30 min | Ministerio para la Transición Ecológica |
| 🇮🇹 Italy | ~23,900 | daily snapshot (08:00 prices) | Ministero delle Imprese e del Made in Italy (MIMIT) |
| 🇦🇺 Western Australia | ~1,000 | one fixed price per day | FuelWatch, Government of WA |

**Try it:** click **Try for free**, keep the prefilled input (cheapest diesel within 10 km of Madrid) and press **Start**. Results appear in seconds.

**Docs and guides:** [fuel-prices-api.pages.dev](https://fuel-prices-api.pages.dev/) — [API reference](https://fuel-prices-api.pages.dev/api/), [MCP for AI agents](https://fuel-prices-api.pages.dev/mcp/), [Python](https://fuel-prices-api.pages.dev/guides/python-european-fuel-prices/) and [JavaScript](https://fuel-prices-api.pages.dev/guides/javascript-fuel-station-prices/) tutorials.

### Quick answers

- **Is there a fuel prices API for Europe?** Yes — this Actor serves France, Spain and Italy (plus Western Australia) through one API, normalized to the same fields.
- **How do I get the cheapest fuel near a location?** Send `latitude`, `longitude`, `radiusKm` and `fuelTypes`; results come sorted cheapest-first with `distanceKm` on each row.
- **Can an AI agent use it?** Yes, as a tool through the [Apify MCP server](#use-it-from-ai-agents-mcp) (Claude, ChatGPT, Cursor, VS Code and other MCP clients).
- **What does it cost?** $0.005 per run + $0.0005 per price row. "Cheapest 10 stations near me" ≈ $0.01.
- **Where does the data come from?** Only official government open-data feeds, reused under their licences (see [Data sources](#data-sources-and-licences)).

### What you can do

- **Find the cheapest station near a point** — radius search, sorted by price or distance.
- **Monitor prices in an area** — schedule runs hourly or daily and send results to Google Sheets, a webhook, S3 or your database through Apify integrations.
- **Compare brands or competitors** — filter by brand around your own stations.
- **Build apps and dashboards** — one integration instead of four different government formats.
- **Give an AI assistant real fuel prices** — "Where is the cheapest diesel within 5 km of these coordinates?"

### Coverage by country

#### France fuel prices (prix des carburants)

Gazole (diesel), SP95, SP95-E10, SP98, E85 and GPLc (LPG) for ~9,800 stations, updated about every 10 minutes from the DGCCRF instant feed. Each price has its own update timestamp. The French feed does not publish station names or brands.

#### Spain fuel prices (precio de la gasolina y el gasóleo)

Gasolina 95/98 (E5 and E10), Gasóleo A and Premium, GLP, GNC/GNL, hydrogen and renewable diesel for ~11,500 stations, refreshed about every 30 minutes by the Ministry. Includes brand (`Rótulo`) and a flag for members-only stations.

#### Italy fuel prices (prezzi carburanti)

Benzina, Gasolio, GPL, Metano, GNL and branded premium fuels for ~23,900 stations, from MIMIT's daily open-data snapshot (prices in force at 08:00 the previous day). Self-service and attended prices are separate rows (`serviceType`).

#### Western Australia fuel prices

Unleaded 91, Premium 95, 98 RON, Diesel, Brand diesel, LPG and E85 for ~1,000 FuelWatch stations. WA prices are fixed for the whole day from 06:00 AWST.

### Quick start inputs

**Cheapest diesel within 10 km of Madrid (top 20):**

```json
{ "latitude": 40.4168, "longitude": -3.7038, "radiusKm": 10, "fuelTypes": ["diesel"], "maxResults": 20 }
```

The country is detected from the coordinates, so only the Spanish feed is downloaded.

**Paris, all fuels, prices updated in the last 24 h:**

```json
{ "countries": ["FR"], "postalCodes": ["75"], "maxPriceAgeHours": 24 }
```

**Nearest stations in central Milan:**

```json
{ "latitude": 45.4642, "longitude": 9.19, "radiusKm": 3, "sortBy": "distance", "maxResults": 50 }
```

**Competitor watch — Repsol and Cepsa stations in Málaga, unleaded 95:**

```json
{ "countries": ["ES"], "cities": ["Málaga"], "brands": ["repsol", "cepsa"], "fuelTypes": ["gasoline_95"] }
```

**Perth, unleaded 91:**

```json
{ "latitude": -31.9523, "longitude": 115.8613, "radiusKm": 15, "fuelTypes": ["gasoline_91"] }
```

### Use it from the API

You need an Apify account and API token ([Console → Settings → API & Integrations](https://console.apify.com/settings/integrations)). The synchronous endpoint runs the Actor and returns the rows in one HTTP call.

**cURL**

```bash
curl -X POST "https://api.apify.com/v2/acts/sste~official-fuel-prices/run-sync-get-dataset-items" \
  -H "Authorization: Bearer $APIFY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"latitude":48.8566,"longitude":2.3522,"radiusKm":3,"fuelTypes":["diesel"],"maxResults":10}'
```

**Python** (`pip install apify-client`)

```python
import os
from apify_client import ApifyClient

client = ApifyClient(os.environ["APIFY_TOKEN"])
run = client.actor("sste/official-fuel-prices").call(run_input={
    "latitude": 41.3874, "longitude": 2.1686,   # Barcelona
    "radiusKm": 5, "fuelTypes": ["gasoline_95"], "maxResults": 10,
})
for row in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(row["price"], row["currency"], row["brand"], row["address"], row["distanceKm"], "km")
```

**JavaScript / Node.js** (`npm install apify-client`)

```js
import { ApifyClient } from 'apify-client';

const client = new ApifyClient({ token: process.env.APIFY_TOKEN });
const run = await client.actor('sste/official-fuel-prices').call({
    latitude: 45.4642, longitude: 9.19,   // Milan
    radiusKm: 3, fuelTypes: ['diesel'], sortBy: 'distance', maxResults: 10,
});
const { items } = await client.dataset(run.defaultDatasetId).listItems();
console.log(items.map((r) => `${r.price} ${r.currency} — ${r.stationName ?? r.address} (${r.distanceKm} km)`));
```

Generated docs for this Actor: [OpenAPI definition](https://apify.com/sste/official-fuel-prices/api/openapi) · [Python](https://apify.com/sste/official-fuel-prices/api/python) · [JavaScript](https://apify.com/sste/official-fuel-prices/api/javascript) · [CLI](https://apify.com/sste/official-fuel-prices/api/cli).

### Use it from AI agents (MCP)

Add the Actor as a tool through the hosted Apify MCP server:

```
https://mcp.apify.com?tools=sste/official-fuel-prices
```

Claude Desktop, Cursor or VS Code configuration (OAuth sign-in opens on first use):

```json
{
  "mcpServers": {
    "fuel-prices": { "url": "https://mcp.apify.com?tools=sste/official-fuel-prices" }
  }
}
```

Local alternative: `npx @apify/actors-mcp-server --tools sste/official-fuel-prices` (with `APIFY_TOKEN` set). More: [MCP page for this Actor](https://apify.com/sste/official-fuel-prices/api/mcp).

Example prompts an agent can answer with this tool:

- "Find the 5 cheapest diesel stations within 5 km of 48.8566, 2.3522."
- "What does unleaded 95 cost near the centre of Valencia today?"
- "List the nearest LPG stations to Perth CBD with their prices."

Tips for agents: always pass `fuelTypes` and a small `maxResults` (the price is per row); pass coordinates rather than place names (there is no geocoding); prices are in the local currency and unit given by `currency` and `unit`.

### Input

| Field | Type | Description |
|---|---|---|
| `countries` | array | `FR`, `ES`, `IT`, `AU-WA`. Empty → auto-detected from the location, or all sources if no location. |
| `fuelTypes` | array | Normalized fuel types (see table below). Empty → all. |
| `latitude`, `longitude` | number | Search centre (WGS84). |
| `radiusKm` | number | 0.1–500, default 10. Adds `distanceKm` to each row. |
| `postalCodes` | array | Prefix match (`"75"`, `"28001"`). FR and ES only. |
| `cities` | array | Exact city/suburb name, case- and accent-insensitive. |
| `brands` | array | Brand contains any of these words. Not available for FR. |
| `maxPriceAgeHours` | integer | Drop prices older than this. |
| `excludeRestricted` | boolean | Drop Spanish members-only stations (cooperatives, fleets). |
| `sortBy` | string | `price` (default, cheapest first within each fuel/currency), `distance`, `none`. |
| `maxResults` | integer | 1–200,000, default 1,000. When sorting by price across several fuels, the limit is shared fairly so every fuel keeps its cheapest stations. |

Invalid input fails immediately with a clear message (nothing is charged per row). If one government feed is temporarily unavailable, the run still returns the other countries and lists the failure in the `SUMMARY` record.

### Output

One row = one fuel price at one station. Real example (Milan):

```json
{
  "id": "IT:56141:Benzina:full",
  "country": "IT",
  "region": "MI",
  "city": "MILANO",
  "postalCode": null,
  "address": "Via Giuseppe Ripamonti 567 20142",
  "stationId": "56141",
  "stationName": "IP",
  "brand": "Api-Ip",
  "latitude": 45.4713,
  "longitude": 9.1919,
  "fuelType": "gasoline_95",
  "fuelName": "Benzina",
  "price": 1.99,
  "currency": "EUR",
  "unit": "L",
  "serviceType": "full",
  "accessRestricted": null,
  "priceUpdatedAt": "2026-09-30T19:42:31+02:00",
  "distanceKm": 0.8,
  "sourceKey": "IT",
  "source": "Ministero delle Imprese e del Made in Italy (MIMIT) — Osservaprezzi Carburanti",
  "sourceUrl": "https://www.mimit.gov.it/it/open-data/elenco-dataset/carburanti-prezzi-praticati-e-anagrafica-degli-impianti",
  "license": "IODL 2.0",
  "fetchedAt": "2026-10-03T16:57:30.326Z"
}
```

A `SUMMARY` record in the run's key-value store lists per-source status, row counts, timings, warnings and the attribution for the sources used.

#### Normalized fuel types

| `fuelType` | France | Spain | Italy | Western Australia |
|---|---|---|---|---|
| `gasoline_91` | — | — | — | Unleaded Petrol (ULP) |
| `gasoline_95` | SP95 | Gasolina 95 E5 | Benzina | Premium Unleaded |
| `gasoline_95_e10` | E10 | Gasolina 95 E10 | — | — |
| `gasoline_98` | SP98 | Gasolina 98 E5 | — | 98 RON |
| `gasoline_98_e10` | — | Gasolina 98 E10 | — | — |
| `gasoline_premium` | — | Gasolina 95 E5 Premium | branded (Blue Super, V-Power…) | — |
| `e85` | E85 | Gasolina 95 E85 | — | E85 |
| `diesel` | Gazole | Gasóleo A | Gasolio (incl. winter grades) | Diesel |
| `diesel_premium` | — | Gasóleo Premium | branded (Blue Diesel, Hi-Q…) | Brand diesel |
| `hvo` | — | Diésel Renovable | HVO, HVOlution… | — |
| `lpg` | GPLc | GLP | GPL | LPG |
| `cng` (kg) | — | Gas Natural Comprimido | Metano, L-GNC | — |
| `lng` (kg) | — | Gas Natural Licuado | GNL | — |
| `hydrogen` (kg) | — | Hidrógeno | — | — |
| `other` | — | Gasóleo B, biofuels… | rare labels | — |

### Coverage differences (what each government publishes)

| Field | FR | ES | IT | AU-WA |
|---|---|---|---|---|
| Station name | ✗ | ✗ | ✓ | ✓ |
| Brand | ✗ | ✓ | ✓ | ✓ |
| Postal code | ✓ | ✓ | ✗ (inside `address`) | ✗ |
| Coordinates | ✓ | ✓ | ✓ | ✓ |
| Timestamp per price | ✓ | feed-level (every ~30 min) | ✓ | daily price, effective 06:00 AWST |
| Self vs attended price | ✗ | ✗ | ✓ (`serviceType`) | ✗ |
| Members-only flag | ✗ | ✓ (`accessRestricted`) | ✗ | ✗ |

Fields a government does not publish are returned as `null`; nothing is guessed.

### Pricing

Pay per event: **$0.005 per run** + **$0.50 per 1,000 price rows** ($0.0005 per row). The run fee is charged once per GB of memory; the default 512 MB is enough for every query.

| Typical run | Rows | Cost |
|---|---|---|
| Cheapest 10 stations near a point | 10 | ≈ $0.01 |
| A city, one fuel | ~200 | ≈ $0.10 |
| All of Spain, all fuels | ~40,000 | ≈ $20 |

Use `maxResults` and filters to pay only for what you need. You can also set a maximum charge per run; the Actor stops cleanly when it is reached.

### Data sources and licences

| Source | Licence | Attribution |
|---|---|---|
| France — [data.economie.gouv.fr, *Prix des carburants en France – flux instantané v2*](https://data.economie.gouv.fr/explore/dataset/prix-des-carburants-en-france-flux-instantane-v2/) (DGCCRF) | [Licence Ouverte v2.0 (Etalab)](https://www.etalab.gouv.fr/licence-ouverte-open-licence/) — commercial reuse allowed | Source in every row; `priceUpdatedAt` per price |
| Spain — MITECO/MINTUR REST service *Precios de carburantes* ([Geoportal Gasolineras](https://geoportalgasolineras.es/)) | Reuse of public-sector information, Ley 37/2007 — content not altered, source and update date cited | Source + `priceUpdatedAt` in every row |
| Italy — [MIMIT *Carburanti – prezzi praticati e anagrafica degli impianti*](https://www.mimit.gov.it/it/open-data/elenco-dataset/carburanti-prezzi-praticati-e-anagrafica-degli-impianti) | [IODL 2.0](https://www.dati.gov.it/iodl/2.0/) — commercial reuse allowed with attribution | Source in every row |
| Western Australia — [FuelWatch](https://www.fuelwatch.wa.gov.au) RSS | Free use on the condition that FuelWatch is acknowledged as the source with a link to [www.fuelwatch.wa.gov.au](https://www.fuelwatch.wa.gov.au) | Source + link in every row |

This Actor is an independent tool and is not affiliated with or endorsed by any of these agencies. Prices are as published by the official sources; always confirm at the pump.

### Limitations

- France and Spain do not publish station names; France does not publish brands.
- Italy publishes a **daily** snapshot (prices in force at 08:00 the previous day), not real-time prices.
- Western Australia publishes one fixed price per day; stations outside the FuelWatch area are not required to report.
- Distances are straight-line (haversine), not driving distance. There is no address geocoding: provide coordinates.
- Austria, Germany, Portugal and the UK are not included yet.

### FAQ

**Is this scraping?** No. The Actor downloads only the files and feeds the governments publish for reuse.

**Do I need an API key for the government data?** No. You only need an Apify account to run the Actor (via Console, API or MCP).

**How fresh is the data?** Each run downloads the latest official feed. `priceUpdatedAt` tells you when the price was last reported (FR/IT per price, ES per feed, WA per day).

**Why are some French prices old?** Some stations report rarely. Use `maxPriceAgeHours` to filter them out.

**Can I get prices in miles per gallon or USD?** No — prices are returned exactly as published: EUR (or AUD) per litre, or per kg for CNG, LNG and hydrogen.

**Do you cover the US or Canada?** No — this Actor only uses official government open data, and only for the four regions above.

**I need another country.** Open an issue on the Issues tab with the country and, ideally, a link to its official open-data feed.

# Changelog

This Actor's version history is a separate document: https://apify.com/sste/official-fuel-prices/changelog.md

# Actor input Schema

## `countries` (type: `array`):

Official sources to query. Leave empty to auto-select from the location below, or to query all sources when no location is given.

## `fuelTypes` (type: `array`):

Normalized fuel types. Leave empty for all fuels. The original label from the official feed is always kept in `fuelName`.

## `latitude` (type: `number`):

Search around a point (WGS84 decimal degrees). Use together with longitude and radius.

## `longitude` (type: `number`):

WGS84 decimal degrees.

## `radiusKm` (type: `number`):

Maximum straight-line distance from the point. Each result gets a `distanceKm` field.

## `postalCodes` (type: `array`):

Keep stations whose postal code starts with one of these values, e.g. "75" for Paris or "28001". Not available for Italy and Western Australia (the official feeds have no postal code).

## `cities` (type: `array`):

Exact city or suburb name, case- and accent-insensitive (e.g. "Málaga", "MILANO", "Perth").

## `brands` (type: `array`):

Keep stations whose brand contains one of these words (e.g. "repsol", "eni", "ampol"). Brand is not published by the French feed.

## `maxPriceAgeHours` (type: `integer`):

Drop prices last updated more than this many hours ago. Useful for France, where some stations report infrequently.

## `excludeRestricted` (type: `boolean`):

Spain flags stations that only sell to members (cooperatives, fleets). Enable to drop them.

## `sortBy` (type: `string`):

"price" sorts cheapest first within each fuel type and currency; "distance" needs a location.

## `maxResults` (type: `integer`):

Upper bound on output rows (one row = one fuel price at one station). You are charged per row.

## Actor input object example

```json
{
  "countries": [
    "ES"
  ],
  "fuelTypes": [
    "diesel"
  ],
  "latitude": 40.4168,
  "longitude": -3.7038,
  "radiusKm": 10,
  "excludeRestricted": false,
  "sortBy": "price",
  "maxResults": 1000
}
```

# Actor output Schema

## `prices` (type: `string`):

No description

## `pricesAllFields` (type: `string`):

No description

## `summary` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "countries": [
        "ES"
    ],
    "fuelTypes": [
        "diesel"
    ],
    "latitude": 40.4168,
    "longitude": -3.7038
};

// Run the Actor and wait for it to finish
const run = await client.actor("sste/official-fuel-prices").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "countries": ["ES"],
    "fuelTypes": ["diesel"],
    "latitude": 40.4168,
    "longitude": -3.7038,
}

# Run the Actor and wait for it to finish
run = client.actor("sste/official-fuel-prices").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "countries": [
    "ES"
  ],
  "fuelTypes": [
    "diesel"
  ],
  "latitude": 40.4168,
  "longitude": -3.7038
}' |
apify call sste/official-fuel-prices --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,sste/official-fuel-prices"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/YJpFN4sFCkxyTWGc9/builds/e7rwefd2ys0I3Nhgz/openapi.json
