Spain Electricity Prices & Demand API
Spanish electricity market series from Red Electrica: PVPC and spot prices, national demand and the generation mix by technology, as one typed row per series and time step.
$0.50 per 1,000 records
You pay only for the records you get. Zero records cost zero. 10,000 free records of this API to start (5,000 at the base price of $1 per 1,000), no card.
Data from apidatos.ree.es/en/datos/mercados/precios-mercados-tiempo-real
Get this data
Try it here with a few records, download the sample, fill a Google Sheet, or call it from your own code.
Try it
Run it on this page, or call it from your code with the endpoint in the developer section. A free key covers 10,000 records of this API, no card. Create a free key
For developers: the API and MCPThe endpoint, code in curl, JavaScript and Python, every input, and files for your tools
- Small runs answer in the same request; longer ones answer
202with a run to poll. fieldsreturns only the fields you name. The examples send the ones picked on this page.Idempotency-Keyis optional. A retry with it is never charged twice.- You pay for records returned. Zero records cost zero.
curl -X POST "https://pullrow.dev/v1/apis/spain-electricity-market/run" \
-H "Authorization: Bearer $PULLROW_API_KEY" \
-H "Content-Type: application/json" \
-d '{"input":{"data_type":"prices"},"max_items":50}'Inputs
Send them as input in the request body. Leave one out to use its default.
What's in each record
6 fields.
Basics
- Series
Series name, such as PVPC, Spot market price, Demand, Wind or Nuclear.
Example PVPC
- Value
Value in the unit given in unit.
Example 237.5
- Percentage
Share of the total for that step, 0 to 1 (for the generation mix: share of all generation).
Example 0.46798
- Unit
EUR/MWh for prices, MWh for demand and generation.
Example EUR/MWh
- Place
Area: peninsular (prices) or national (demand and generation).
Example peninsular
Dates
- Datetime
Start of the time step (UTC).
Example Dec 3, 2026
Technical detailsField names and types for developers
Field names and types
The names your code reads in each record. "Filled" counts how many of the 3 sample records carry the field.
| Field name | Type | Shown on this page as | Filled |
|---|---|---|---|
series | text | Series | 3 of 3 |
datetime | date and time | Datetime | 3 of 3 |
value | number | Value | 3 of 3 |
percentage | number | Percentage | 3 of 3 |
unit | text | Unit | 3 of 3 |
geo | text | Place | 3 of 3 |
How it reads the site
Runs on a reader we built and maintain by hand for this site.
Save as pipeline
A pipeline remembers this API, your inputs and the fields you picked. It can run on a schedule and email you the results.
Sample records
| Record | Series | Value | Percentage | Unit | Place | Datetime |
|---|---|---|---|---|---|---|
| 1 | PVPC | 237.5 | 0.46798 | EUR/MWh | peninsular | Dec 3, 2026 |
| 2 | PVPC | 215.23 | 0.466644 | EUR/MWh | peninsular | Dec 4, 2026 |
| 3 | PVPC | 194.43 | 0.459287 | EUR/MWh | peninsular | Dec 4, 2026 |
Sample records from the example output this API publishes. Email addresses and phone numbers in them are masked. Hover over a column name to see the field name your code reads.
Reliability
Counted from real runs. Our own health checks are left out. A run succeeded when it finished and the site neither blocked it nor broke it.
Incidents and repairs
How it is kept working What a repair can't do
A ready-made API, maintained by us. It is not part of the daily check or the automatic rebuild yet.
- You pay only for records returned. A run that returns none costs nothing.
- Prices (PVPC and spot, EUR/MWh) can be read by hour, day or month; demand and the generation mix (MWh) by day or month only, because the source refuses hourly steps for them.
- Prices cover the Spanish mainland (peninsular) market; demand and generation are national totals.
- The source publishes next-day prices in the afternoon and revises recent demand and generation figures; the latest days can change.
- Source reuse is free with credit to Red Electrica (REData); no request limit is published, so requests are spaced out. A single request returns a whole period, so large periods give many rows.
Version history
A run uses the live version unless the request names another one with version.
Manage this API
Only your workspace sees this part.
Automatic repair
Off: a rebuilt version is stored and waits for you in the version history.
Delete this API
Removes the API, its versions and the saved records of its runs. Calls to its address then answer 404. Records already charged stay charged. This cannot be undone.