Spain Electricity Prices – PVPC & Spot per Hour (Luz)
Pricing
$3.00 / 1,000 daily electricity prices
Spain Electricity Prices – PVPC & Spot per Hour (Luz)
Hourly electricity prices in Spain (PVPC regulated tariff and REE spot market) per day and zone, with the cheapest hours of each day.
Pricing
$3.00 / 1,000 daily electricity prices
Rating
0.0
(0)
Developer
FlEtsv
Maintained by CommunityActor stats
0
Bookmarked
2
Total users
1
Monthly active users
2 days ago
Last modified
Categories
Security
Limited permissionsShare
Precios de la luz España – PVPC y spot hora a hora
Use cases
- Schedule appliances, EV charging or crypto/compute jobs in the cheapest hours of the day
- Energy dashboards and home-automation (Home Assistant, n8n) fed with PVPC and spot prices
- Energy-cost reporting for businesses and comparison sites
- Price-alert bots for the Spanish electricity market
Español
¿Qué hace?
Descarga los precios de la electricidad en España hora a hora para el rango de días que indiques y la zona eléctrica que elijas. Publica dos series: el PVPC (la tarifa regulada de consumidores acogidos a precio voluntario para el pequeño consumidor) y el precio spot del mercado mayorista de REE. Por cada día devuelve la media, el mínimo y el máximo, y la lista de las horas más baratas para que puedas programar consumos.
Los datos son los que publica Red Eléctrica de España (REE) en sus servicios públicos. El Actor no almacena nada fuera de la ejecución.
Input
| Campo | Tipo | Por defecto | Descripción |
|---|---|---|---|
fechaInicio | texto AAAA-MM-DD | hoy (Europe/Madrid) | Primer día a consultar. No anterior a 2014-04-01. |
fechaFin | texto AAAA-MM-DD | mañana | Último día a consultar. REE publica hasta el día siguiente. |
zona | peninsular, canarias, baleares, ceuta o melilla | peninsular | Zona eléctrica. |
horasBaratas | entero 1–24 | 6 | Cuántas horas baratas listar por día. |
pausaMs | entero 0–10000 | 300 | Pausa entre peticiones a REE, en milisegundos. |
Como máximo se procesan 366 días por ejecución. Si fechaInicio es posterior a fechaFin, o alguna fecha tiene otro formato, la ejecución se detiene con un error claro.
Ejemplo mínimo:
{"fechaInicio":"2026-10-30","fechaFin":"2026-10-31","zona":"peninsular","horasBaratas":3}
Output
Un registro por día y zona en el dataset, con estos campos principales:
fecha,zonayprecioReferencia(pvpcospot).horas: de 24 a 25 registros horarios, cada uno conhora,fechaHora,pvpcyspot.horasMasBaratas: las horas más baratas del día segúnhorasBaratas.precioMedio,precioMinimoyprecioMaximo, en EUR/MWh tal como los publica REE.fuentesyextraidoEn, para saber de dónde sale cada dato y cuándo se extrajo.
La vista «Daily prices» resume cada día en una tabla.
Precios (pago por evento)
Se cobra el evento dia a 0,003 USD por día procesado. Un rango de 30 días cuesta 0,09 USD. Si el tope de gasto que hayas configurado se alcanza, la ejecución se detiene y guarda lo ya obtenido.
Pricing
You pay per event: the dia event costs USD 0.003 per day of data returned. A 30-day range costs USD 0.09. If your spending limit is reached, the run stops and keeps the results already collected.
Fuente y licencia
Los precios proceden de los servicios públicos de Red Eléctrica de España (REE). Consulta las condiciones de reutilización de REE antes de publicar o redistribuir los datos.
Source: Red Eléctrica de España (REE) public price services. Check REE's reuse conditions before redistributing the data.
Integrations (Make, Zapier, Google Sheets)
- Make: add the Apify module "Run an Actor" (Actor
Flets_sv/precios-luz-espana), paste the input JSON, chain "Get Dataset Items" and map the fields to Google Sheets, Slack, Airtable or your CRM. - Zapier: the Apify app offers "Run Actor" and "Fetch Dataset Items". Add a Schedule trigger and send each row to Gmail, Slack or Notion.
- Google Sheets: enable the official Google Sheets integration in the Actor's Integrations tab to append every run to a sheet, or call
https://api.apify.com/v2/acts/Flets_sv~precios-luz-espana/run-sync-get-dataset-items?format=csvwith POST and your input from Apps Script (UrlFetchApp). - API and webhooks: start the Actor from the REST API, use Schedules for recurring runs and add a webhook to notify your system when a run finishes.
Input to paste into Make or Zapier:
{"zona":"peninsular","horasBaratas":6,"pausaMs":300}
FAQ
¿Por qué falta el día de mañana? Si REE aún no ha publicado el spot del día siguiente, el Actor avisa y omite ese día en lugar de inventarlo.
¿Qué diferencia hay entre PVPC y spot? El PVPC es la tarifa regulada que aplican las comercializadoras a los consumidores acogidos; el spot es el precio del mercado mayorista. Los dos se publican por hora en el mismo registro.
¿Puedo consultar un año entero? Hay que partirlo en tramos de como máximo 366 días por ejecución.
English
What does it do?
Downloads hour-by-hour electricity prices in Spain for the date range and electrical zone you choose. It publishes two series: the PVPC regulated tariff and the REE spot wholesale price. For each day it returns the average, minimum and maximum, plus the cheapest hours so you can schedule consumption.
Data comes from the public services of Red Eléctrica de España (REE). The Actor stores nothing outside the run.
Input
See the table in the Spanish section above: fechaInicio, fechaFin, zona, horasBaratas and pausaMs. Dates are YYYY-MM-DD, empty dates mean today and tomorrow, and a run covers at most 366 days.
Output
One dataset record per day and zone, with hourly horas, horasMasBaratas, daily precioMedio, precioMinimo and precioMaximo (EUR/MWh), sources and extraction time.
Pricing
You pay per event: the dia event costs USD 0.003 per day of data returned. A 30-day range costs USD 0.09.
FAQ
Why is tomorrow's data missing? REE publishes next-day spot prices in the afternoon. If they are not out yet, the Actor reports the day and skips it.
Can I fetch a full year? Split it into runs of at most 366 days.
Integraciones (Make, Zapier, Google Sheets)
- Make: añade el módulo de Apify «Run an Actor» (Actor
Flets_sv/precios-luz-espana), pega el input JSON y encadena «Get Dataset Items»; después mapea los campos a Google Sheets, Slack, Airtable o tu CRM. - Zapier: la app de Apify ofrece «Run Actor» y «Fetch Dataset Items». Ponle un disparador de horario y envía cada fila a Gmail, Slack o Notion.
- Google Sheets: en la pestaña Integrations del Actor activa la integración oficial con Google Sheets para añadir cada ejecución a una hoja, o llama desde Apps Script (
UrlFetchApp) ahttps://api.apify.com/v2/acts/Flets_sv~precios-luz-espana/run-sync-get-dataset-items?format=csvcon POST y tu input. - API y webhooks: lanza el Actor por API REST, programa ejecuciones (Schedules) y avisa a tu sistema con un webhook al terminar.
Ejemplo de input para pegar en Make o Zapier:
{"zona":"peninsular","horasBaratas":6,"pausaMs":300}
Ejemplos de uso / Usage examples
Example output (real run, 2026-11-05)
First rows returned by a real run of this Actor on 2026-11-05 (shortened columns, values truncated):
| fecha | zona | precioMedio | precioMinimo | precioMaximo | horasMasBaratas |
|---|---|---|---|---|---|
| 2026-10-29 | peninsular | 240.04916666666668 | 107.01 | 395.97 | {"hora": 14, "fechaHora": "2026-10-29T13:00:00.000Z", "pv... |
| 2026-10-30 | peninsular | 239.04791666666662 | 140.17 | 382.47 | {"hora": 14, "fechaHora": "2026-10-30T13:00:00.000Z", "pv... |
| 2026-10-31 | peninsular | 195.2216666666667 | 21.48 | 325.94 | {"hora": 14, "fechaHora": "2026-10-31T13:00:00.000Z", "pv... |
Copy-paste inputs
1. Hourly PVPC for the mainland and the 3 cheapest hours
{"fechaInicio": "2026-10-30","fechaFin": "2026-10-31","zona": "peninsular","horasBaratas": 3}
2. Canary Islands, one week
{"fechaInicio": "2026-10-25","fechaFin": "2026-10-31","zona": "canarias","horasBaratas": 5}
Call it from your code (Apify API)
curl -X POST "https://api.apify.com/v2/acts/Flets_sv~precios-luz-espana/run-sync-get-dataset-items?token=YOUR_API_TOKEN" \-H "Content-Type: application/json" \-d '{"fechaInicio": "2026-10-30", "fechaFin": "2026-10-31", "zona": "peninsular", "horasBaratas": 3}'
from apify_client import ApifyClientclient = ApifyClient("YOUR_API_TOKEN")run = client.actor("Flets_sv/precios-luz-espana").call(run_input={"fechaInicio": "2026-10-30", "fechaFin": "2026-10-31", "zona": "peninsular", "horasBaratas": 3})for item in client.dataset(run["defaultDatasetId"]).iterate_items():print(item)
No code? Use the Apify modules for Make and Zapier (run the Actor, then fetch dataset items), or the Google Sheets integration in the Actor's Integrations tab to append each run to a sheet.