Madrid to Donostia / San Sebastian train

Trains from Madrid to Donostia / San Sebastian start at €42.14 and take 3h 33m at their fastest.

MadridMadridDonostia / San SebastiánDonostia / San Sebastián

The Trains from Madrid to Donostia / San Sebastian starts at €42.14 and takes 3h 33m door to door, run by 2 operators over 405 km, with around 6 departures a day. Fares bottom out about 90 days before departure.

Checked September 15, 2026Priced for September 29, 2026One passenger, all fees included

  • 3h 33mDoor to door
  • 2h 49mMoving
  • €42.14 to €124.09From
  • 06:12 to 07:30First and last departure
  • 6Per day
  • 13.4 kgCO2

First and last are taken from the services we sell on September 29, 2026. The return direction keeps its own timetable and is not these times reversed.

€42.14 to €124.09 for one passenger across the 14 departure dates priced here. The low end is one day, not every day. Worked out from this corridor rather than held for anybody. The operator sets the price on the day.

Fares by date

What this journey usually costs, by departure date. It shows which days run dearer.

Typical fares

  1. about €87.24Wed16
  2. about €124.09Thu17
  3. about €83.39Fri18
  4. about €83.94Sat19
  5. about €79.54Sun20
  6. about €64.14Mon21
  7. about €55.34Tue22
  8. about €55.34Wed23
  9. about €77.89Thu24
  10. about €72.39Fri25
  11. about €66.89Sat26
  12. about €67.44Sun27
  13. about €48.19Mon28
  14. about €42.14Tue29

Based on what this route has cost recently. The operator sets the price on the day, and the live fare is confirmed when you book.

Real services

The cheapest and the fastest on September 29, 2026

Cheapest€42.14
  1. Renfe R262707:301h 57m09:27Madrid Puerta de AtochaLogroño railway station
  2. Renfe R743810:431h11:43Logroño railway stationHernani

Changes at Logroño, with 76 minutes between services and a walk of about 5 minutes.

Door to door 4h 57mCO2 12.1 kgChanges 1Refundable

Fastest€60.84
  1. Renfe Feve RF161406:492h 49m09:38Madrid Puerta de AtochaHernani

Door to door 3h 33mCO2 13.4 kgChanges 0Refundable

Carriers

Rail operators

Every operator we sell on this corridor. Speed is the carrier's own typical cruising speed, not the average over this route.
OperatorFrom
Renfe€50.94
Renfe Feve€44.34
  • Renfe
  • Renfe Feve

The train gets you into Donostia / San Sebastian. It does not get you a bed, and neither do we.

A hotel room

A room in Donostia / San Sebastian for the night the train gets in

Sort by distance from Hernani and you can see which places are ten minutes on foot and which are not.

Partner links. We do not sell accommodation. We earn a commission when a booking completes, and it never changes what you pay.

Booking window

When to book Madrid to Donostia / San Sebastian

The same search run across the whole booking window, so the shape of the curve is visible rather than described.

  1. €42.1490 days
  2. €47.0960 days
  3. €47.0945 days
  4. €50.9430 days
  5. €44.3421 days
  6. €42.1414 days
  7. €55.347 days
  8. €83.393 days
  9. €87.241 days
Cheapest lead time
Fares bottom out around 90 days ahead, at €42.14.
How much it moves
The gap between the cheapest and most expensive lead time is 107 percent. The most expensive point is €87.24, 1 days out.
What that means
Today sits inside the cheap window, which closes about 90 days before departure. Waiting from here has usually cost money on this corridor rather than saved it.
Day of the week

Which departure day costs least

Median cheapest fare for each weekday, taken across the next three weeks of real prices.

  1. €67.44Sun
  2. €48.19Mon
  3. €44.34Tue
  4. €55.34Wed
  5. €77.89Thu
  6. €72.39Fri
  7. €66.89Sat
Terminals

Where you leave from and where you arrive

Madrid

Rail
  • Madrid Puerta de Atocha
  • Madrid Atocha
  • Estación del Norte, Madrid

Donostia / San Sebastián

Rail
  • Hernani
  • Herrera
  • Urnieta
The journey

What the journey actually looks like

Direct or connecting
33% of the services we sell on this corridor run through without a change. The remaining 67% involve one connection.
How far it really runs
The route covers 405 km against 352 km in a straight line, a detour of 15 percent. Track and road geometry account for the difference.
Where the change is
Connections are made at Pamplona, Logroño, Gasteiz / Vitoria, Burgos. The gap between arriving and leaving is 48 minutes, of which about 5 is walking.
If the connection is missed
The tightest connection we sell here has a 19 percent chance of not being made on the timetable alone. Part of this journey is a self transfer between separate tickets, so leave more time than the minimum and expect to check in again.
First and last departure
The first service of the day leaves Madrid at 06:12 and the last at 07:30, across 6 departures The return direction keeps its own timetable, so the times back are not these times reversed.

Questions about Madrid to Donostia / San Sebastian

The questions people actually ask about this trip, answered from the same prices and times the page above is built on rather than written once and left to go stale.

How long does the Train from Madrid to Donostia / San Sebastian take?

The Train from Madrid to Donostia / San Sebastian takes 3h 33m door to door, of which 2h 49m is spent moving. The route runs 405 km. The difference between the two times is reaching the terminal and leaving it at the far end, which every time on this page includes.

How much does the Train from Madrid to Donostia / San Sebastian cost?

The Train from Madrid to Donostia / San Sebastian starts at €42.14 for one passenger, as of September 15, 2026. A typical fare is €50.67. Both are the total including taxes, supplier fees and our service fee, so the price here is the price at checkout.

Who runs the Train from Madrid to Donostia / San Sebastian?

2 operators run the Train from Madrid to Donostia / San Sebastian: Renfe, Renfe Feve. Between them they file around 6 departures a day. The operator table on this page compares them on fare, journey time, cruising speed, fare conditions and what is provided on board.

Which terminal does the Train from Madrid to Donostia / San Sebastian use?

The Train from Madrid to Donostia / San Sebastian leaves from Madrid Puerta de Atocha and arrives at Hernani. Allow about 44m for reaching the departure terminal and leaving the arrival one. That time is already inside every door to door figure quoted on this page.

When should I book the Train from Madrid to Donostia / San Sebastian?

Fares for the Train from Madrid to Donostia / San Sebastian bottom out around 90 days ahead, at €42.14. The gap between the cheapest and most expensive lead time across the window is 107 percent, measured on September 15, 2026. Booking inside the final week has consistently cost more.

How much CO2 does the Train from Madrid to Donostia / San Sebastian produce?

The Train from Madrid to Donostia / San Sebastian produces about 13.4 kg of CO2 per passenger over 405 km, which works out at roughly 33 grams per passenger kilometer. That figure is for the whole journey and for one traveler, not for the vehicle.

What is provided on board the Train from Madrid to Donostia / San Sebastian?

Operators on the Train from Madrid to Donostia / San Sebastian publish Power outlets, Wi-Fi. That is what 2 carriers on this corridor state about their own fleets, across a journey of 3h 33m door to door. Where a carrier publishes nothing, this page lists nothing for it.

Where these numbers come from

Places, coordinates, operators, which operator serves which pair, and every distance on this page are real and come from open data. Where a corridor has a filed timetable the departure times are real too, and ferry fares are the prices the operators publish themselves.

Derived from service area No carrier record names this exact pair. The operators listed publish a service area covering both places at a distance their mode plausibly carries people, which is evidence that the corridor is served and not evidence of a specific service. Pages state which, because presenting the two as the same thing would be dishonest.

Where no operator publishes a fare for a corridor, the price here is our own estimate, worked out from the real distance and the real operator through a fare curve that follows lead time, day of the week and season. It tells you roughly what the journey costs. It is not a seat anyone has agreed to sell, and the payment step will not take it.

Defined in full at Door to door, Fares, The booking window, Carbon

On this page
Every figure above was computed for Madrid to Donostia / San Sebastian on September 15, 2026: 405 km of route against 352 km in a straight line, 6 services a day, 2 operators a cheapest fare of €42.14, and 3h 33m door to door on the fastest mode. The return direction is computed separately and its numbers are not these numbers.

Related journeys

Being on the water gives Donostia / San Sebastian a set of days out that do not start at a station. We do not sell those either.

A guided tour group

Day trips out of Donostia / San Sebastian and across Spain

Day trips that leave Donostia / San Sebastian in the morning and cover a good part of Spain by evening.

Partner links. We do not sell tours or tickets. We earn a commission on a booking, and it never changes the price.

Plan with Ori

Ori, the trip planner

Ask it something like this