# Fuel Prices Scraper (`deriverge/fuel-prices-scraper`) Actor

Fuel prices at every petrol station in France, Spain and Italy from each government's open data, one row per station and fuel with address, coordinates and the time of the last price change. Filter by city, postcode, radius or fuel, rank the lowest prices in an area, or get only changed prices.

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

## Pricing

from $0.40 / 1,000 fuel prices

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

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 Scraper

Fuel Prices Scraper returns pump prices from the official open data of France, Spain and Italy, one row per station and fuel: address, postcode, coordinates, brand (Spain and Italy), a fuel type shared by all three countries, the price per litre or kilogram, when the station last reported it, and the source and licence. Pick a country, type a city such as `Paris` or a postcode, and click **Start**. Italy publishes once a day, so its prices are the ones in force at 8:00 the day before. It costs $0.80 per 1,000 fuel prices on the Free plan ($0.40 on Business), and the $5 of monthly credit in Apify's Free plan covers about 6,200 fuel prices.

### What data does it return?

| Field | Description |
|---|---|
| `country`, `stationId` | ISO country code (`FR`, `ES` or `IT`) and the station's ID in the national source, such as `10943`. |
| `brand` | Brand on the station sign in Spain (`CEPSA`, `BALLENOIL`) or the fuel brand in Italy (`Agip Eni`, `Q8`; `Pompe Bianche` marks an unbranded station). France publishes no brand, so it is always `null` there. |
| `address`, `postcode`, `city` | As the source writes them, often in capitals. Italian postcodes are read from the end of the address and are missing for about 5% of stations. |
| `region` | French department code from the postcode (`75`, `2A`), Spanish province name (`MADRID`) or Italian province code (`RM`). |
| `latitude`, `longitude` | Station coordinates in decimal degrees, such as `40.432861`. |
| `distanceKm` | Distance from the centre of a radius search in kilometres, `null` without one. |
| `roadType` | `motorway` or `road` in France and Italy, `null` in Spain. |
| `fuelType` | One name for the same fuel in every country: `petrol_95`, `petrol_95_e10`, `petrol_98` (98 octane or more), `petrol_premium`, `diesel`, `diesel_premium`, `diesel_agricultural`, `hvo`, `biodiesel`, `e85`, `lpg`, `cng`, `lng`, `hydrogen`, `adblue` or `other`. |
| `fuelName` | The fuel exactly as the source names it, such as `Gazole`, `Gasoleo A` or `Blue Diesel`. |
| `serviceMode` | Italy only: `self` for self-service or `served` for an attended pump. They are separate prices, so they are separate rows. |
| `price`, `currency`, `unit` | Price including taxes in `EUR` per `L`, or per `kg` for CNG, LNG and hydrogen. |
| `updatedAt` | When the station last reported the price, ISO 8601 with the local offset, such as `2026-10-11T08:50:09+02:00`. Spain gives no time per price, so its rows carry the time of the ministry's extract. |
| `openingHours` | Spain only, as the ministry writes them, such as `L-D: 24H` for every day around the clock. |
| `rank`, `area` | Lowest-priced output only: position from 1 and the place the ranking is for. |
| `changeType`, `previousPrice`, `priceChange`, `previousUpdatedAt` | Changes output only: `new`, `up` or `down`, the price in the last run, the difference and when the old price was reported. |
| `priceId` | Key of the price that stays the same between runs, such as `ES-10943-Gasoleo A`. |
| `source`, `licence`, `sourceUpdatedAt`, `sourceUrl` | Publisher, licence, date of the source file and the file the price was read from. Keep them when you publish the data. |
| `scrapedAt` | When the row was produced, ISO 8601 in UTC. |

### How to scrape fuel prices

1. In **Countries**, pick France, Spain, Italy or several of them. Left empty, all three are read.
2. Narrow the area in **Cities or postcodes**: a city as the source writes it (`Paris`, `Madrid`, `Roma`, or English names such as `Rome` and `Seville`), a postcode such as `75015`, or its first digits for a whole French department or Spanish province, such as `28` for Madrid. For a radius search, fill **Latitude**, **Longitude** and **Radius (km)** instead.
3. Pick **Fuel types** and, for Spain and Italy, **Brands**.
4. Choose the **Output**: every matching price, the lowest-priced stations per place and fuel, or only the prices that changed since the last run.
5. Set **Maximum prices** and click **Start**. The rows appear in the **Output** tab, where you can download them as CSV, Excel or JSON. The `SUMMARY` record shows for each country how many stations and prices the file held, how many matched and the date of the file.

Over the API, an input for the three lowest diesel and petrol prices in Madrid and Rome looks like this:

```json
{
  "countries": ["ES", "IT"],
  "locations": ["Madrid", "Rome"],
  "fuelTypes": ["diesel", "petrol_95"],
  "mode": "lowest",
  "stationsPerArea": 3
}
```

### Example output

One diesel price from a Madrid run on 11 October 2026:

```json
{
  "country": "ES",
  "stationId": "10943",
  "brand": "CEPSA",
  "address": "PASEO MORET, 7",
  "postcode": "28008",
  "city": "MADRID",
  "region": "MADRID",
  "latitude": 40.432861,
  "longitude": -3.724194,
  "distanceKm": null,
  "roadType": null,
  "fuelType": "diesel",
  "fuelName": "Gasoleo A",
  "serviceMode": null,
  "price": 1.964,
  "currency": "EUR",
  "unit": "L",
  "updatedAt": "2026-10-11T17:54:07+02:00",
  "openingHours": "L-V: 08:00-21:00; S: 09:00-14:00",
  "priceId": "ES-10943-Gasoleo A",
  "source": "Ministerio para la Transición Ecológica y el Reto Demográfico, Geoportal Gasolineras",
  "licence": "Reuse conditions of Spanish Law 37/2007 on public sector information",
  "sourceUpdatedAt": "2026-10-11T17:54:07+02:00",
  "sourceUrl": "https://sedeaplicaciones.minetur.gob.es/ServiciosRESTCarburantes/PreciosCarburantes/EstacionesTerrestres/",
  "scrapedAt": "2026-10-11T15:54:07.068Z"
}
```

### How much does it cost to scrape fuel prices?

| | Free plan | Starter | Scale | Business |
|---|---|---|---|---|
| 1,000 fuel prices | $0.80 | $0.64 | $0.52 | $0.40 |

You pay only for the events in the table. There is no start fee, and compute time and proxies are included.

Diesel and E10 prices in Paris came to 71 rows on 11 October 2026, which costs $0.0568 on the Free plan. Every price in France that day was 30,728 rows: $24.5824 on the Free plan or $12.2912 on Business. Prices outside your filters and prices unchanged since the last run in changes output are not charged.

### Limits

- Coverage on 11 October 2026: 9,228 French stations with prices, 11,515 Spanish stations including the Balearic and Canary Islands, Ceuta and Melilla, and 21,687 Italian stations, together 166,734 prices.
- Freshness depends on the country. The French file is refreshed about every 10 minutes and the Spanish one every half hour. Italy publishes one file a day with the prices in force at 8:00 the day before.
- Stations report their own prices and some stop. In France 25% of prices were older than 7 days and 3.3% older than 30 days on 11 October 2026, in Italy 2.6% and 0.7%. **Skip prices older than (days)** leaves them out.
- Prices are returned as the station entered them, including a few typing errors such as 0.100 EUR per litre in Italy. The lowest-priced output skips prices below half the median of their place and fuel when at least 5 stations compete.
- France publishes no brand and no station name. Italian station names and operators are left out because many of them are the name of the person who runs the station, and no source gives phone numbers or emails.
- A postcode is matched in every selected country, so `75` also matches Italian postcodes that start with 75 when Italy is selected. Pick the country to avoid that.
- Each run downloads the whole file of each selected country, one request per country and two for Italy: 0.9 MB for France, 11.7 MB for Spain and 7.2 MB for Italy. A Paris run took 3 seconds and all three countries about 45 seconds.
- If a source refuses access or answers with a bot protection page, the actor sends it no further requests, returns the other countries and names the failure in the status message and `SUMMARY`. A run where no source answers fails and charges nothing.

### Sources and licences

| Country | Publisher | Licence | What the licence asks |
|---|---|---|---|
| France | Ministère de l'Économie et des Finances, prix-carburants.gouv.fr | Licence Ouverte / Open Licence 2.0 (Etalab) | Name the source and the date of its last update. Commercial reuse is allowed. |
| Spain | Ministerio para la Transición Ecológica y el Reto Demográfico, Geoportal Gasolineras | Reuse conditions of Spanish Law 37/2007 | Cite the source and the date of the last update, do not alter or distort the content, do not suggest the ministry endorses your use. |
| Italy | Ministero delle Imprese e del Made in Italy (MIMIT), Osservatorio prezzi carburanti | Italian Open Data License 2.0 | Credit the source. Commercial reuse is allowed. |

Every row carries `source`, `licence` and `sourceUpdatedAt`, so the credit travels with the data. The price and the fuel name stay exactly as published; `fuelType` is added next to them. This actor is not affiliated with or endorsed by any of the three ministries.

### Tracking price changes

Set **Output** to only the prices that changed, give a **Watch name** or save the input as a task, and schedule it. The first run returns every matching price as `new` and saves a snapshot. Each later run compares with the snapshot and returns the prices that went `up` or `down`, with `previousPrice` and `priceChange`, and prices that were not there before. On 11 October 2026 a watch on Paris and Madrid compared 1,071 prices: a run three minutes after the first returned none, and a run half an hour later returned 40 (37 up, 3 down). Prices cut off by **Maximum prices** wait for the next run, and the `CHANGES` record counts new, higher, lower and unchanged prices and lists prices that disappeared, for example when a station stops selling a fuel. Italian prices change once a day, so a watch on Italy needs one run a day.

### FAQ

#### Is it legal to use these fuel prices?

The data are open data files that the French, Spanish and Italian governments publish for reuse, under the licences in the table above, and all three allow commercial use with credit to the source. The actor downloads those published files and returns station addresses and prices, with no names of station operators and no contact details. You are responsible for following the licence terms when you publish or resell the data.

#### Why are Germany, Austria and the United Kingdom not covered?

German prices are public through the Tankerkönig API, which needs a personal key and does not allow bulk downloads. Austria's E-Control publishes no licence that allows reuse of its fuel price data. The UK Fuel Finder files answered with HTTP 403 to the cloud servers this actor runs on in October 2026.

#### Why does an Italian station have two prices for the same fuel?

Italian stations post one price for self-service and another for the attended pump, a median of 20 cents apart in October 2026. Both come as rows with `serviceMode` set to `self` or `served`. The lowest-priced output keeps only the lower of the two for each station.

#### Can I get the history of prices?

Each run returns the current files. To build a history, schedule the actor and keep each run's dataset, or use the changes output to store only what moved.

### Support

This actor is built and maintained by deriverge s.r.o., a software company based in the Czech Republic. If a run fails or a field you need is missing, please open an issue in the **Issues** tab or write to us at info@deriverge.com. We respond in English and Czech. Runs can be scheduled in Apify Console or started from the **API** tab, which has examples for Python, JavaScript and cURL and works with Make, Zapier, n8n and the Apify MCP server. If the actor saves you time, a short review helps other people find it.

# Changelog

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

# Actor input Schema

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

Countries to read. Leave empty for all three; with coordinates and no country, only the countries near the point are downloaded.

## `locations` (type: `array`):

Keep only stations in these places: a city or town as the source writes it (Paris, Madrid, Roma; English names of large Italian and Spanish cities such as Rome or Seville work too), a full postcode such as 75015 or 28001, or the first digits of a postcode for a whole French department or Spanish province, such as 75 or 28. Paris, Lyon and Marseille include their districts.

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

Centre of a radius search in decimal degrees, for example 48.8566. Use it with Longitude.

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

Centre of a radius search in decimal degrees, for example 2.3522.

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

Keep stations within this distance of the point. Every row then gets distanceKm and the results are sorted by distance.

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

Keep only these fuels. Leave empty for every fuel the stations sell.

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

Keep only stations whose brand contains one of these words, for example Repsol, Q8 or Eni. France publishes no brand, so this filter leaves out French stations.

## `maxAgeDays` (type: `integer`):

Leave out prices the station has not confirmed for this many days. Empty keeps every price, except in the lowest-priced mode, which uses 7 days unless you set it.

## `mode` (type: `string`):

Latest prices returns every matching price. Lowest-priced stations ranks the stations in each place and fuel by price. Changes compares with the snapshot of the last run of the same watch name or task and returns only new prices and prices that went up or down.

## `stationsPerArea` (type: `integer`):

How many of the lowest-priced stations to return for each place and fuel type.

## `watchName` (type: `string`):

Name of the snapshot the changes mode compares with, for example "madrid-diesel". Runs from a saved task get one automatically.

## `maxItems` (type: `integer`):

Stop after this many rows, so the cost of a run stays predictable. All three countries together hold about 167,000 prices.

## Actor input object example

```json
{
  "countries": [
    "FR"
  ],
  "locations": [
    "Paris"
  ],
  "radiusKm": 10,
  "fuelTypes": [
    "diesel",
    "petrol_95_e10"
  ],
  "mode": "snapshot",
  "stationsPerArea": 5,
  "maxItems": 100
}
```

# Actor output Schema

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

One row per station and fuel with address, coordinates, price, unit, the time of the last price change and the source and licence.

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

Per country: stations and prices in the source, prices that matched, rows returned, the date of the source file and anything that could not be read; plus the attribution of each source.

## `changes` (type: `string`):

Changes mode with a watch name or task: counts of new, higher, lower and unchanged prices and the prices that are no longer published.

# 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": [
        "FR"
    ],
    "locations": [
        "Paris"
    ],
    "fuelTypes": [
        "diesel",
        "petrol_95_e10"
    ],
    "maxItems": 100
};

// Run the Actor and wait for it to finish
const run = await client.actor("deriverge/fuel-prices-scraper").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": ["FR"],
    "locations": ["Paris"],
    "fuelTypes": [
        "diesel",
        "petrol_95_e10",
    ],
    "maxItems": 100,
}

# Run the Actor and wait for it to finish
run = client.actor("deriverge/fuel-prices-scraper").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": [
    "FR"
  ],
  "locations": [
    "Paris"
  ],
  "fuelTypes": [
    "diesel",
    "petrol_95_e10"
  ],
  "maxItems": 100
}' |
apify call deriverge/fuel-prices-scraper --silent --output-dataset

```

## MCP server setup

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

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/IYKhvxbnoqAyShgyc/builds/LDdLMloN4AyBcCoSu/openapi.json
