Say "Hai" to Japan - get your Japan Rail Pass today! 🌸 Take a look

Business

No tickets in your cart.

Why not plan a trip?

My Bookings
Loading...
Loading...

TrainlineTrainline is Europe’s Nº 1 destination for train and bus tickets*

Official distributor

  • renfe
  • iryo
  • ouigo
  • ave
  • avlo
  • tgv_inoui
  • eurostar
  • blablabus
  • alsa
Support image
TrainlineTrainline

Search. Book. Travel.

Say hello to Your Account

All your tickets and travel info, all in one place. Easy as that.

ChatChat

Got a question? Our support team are on hand 24/7.

Companion image
TrainlineTrainline

Search. Book. Travel.

No more fumbling in your pockets

Digital tickets live neatly in our app, so you can just tap, scan and go.

ETicketETicket

All your tickets, all in the palm of your hand.

Calendar week image
TrainlineTrainline

Search. Book. Travel.

Looking for a cheap price?

Look no further. Compare tickets easily with our price calendar.

CalendarCalendar

We’ll find you the cheapest day to travel.

Support image
TrainlineTrainline

Search. Book. Travel.

Say hello to Your Account

All your tickets and travel info, all in one place. Easy as that.

ChatChat

Got a question? Our support team are on hand 24/7.

Companion image
TrainlineTrainline

Search. Book. Travel.

No more fumbling in your pockets

Digital tickets live neatly in our app, so you can just tap, scan and go.

ETicketETicket

All your tickets, all in the palm of your hand.

Calendar week image
TrainlineTrainline

Search. Book. Travel.

Looking for a cheap price?

Look no further. Compare tickets easily with our price calendar.

CalendarCalendar

We’ll find you the cheapest day to travel.

Support image
TrainlineTrainline

Search. Book. Travel.

Say hello to Your Account

All your tickets and travel info, all in one place. Easy as that.

ChatChat

Got a question? Our support team are on hand 24/7.

Companion image
TrainlineTrainline

Search. Book. Travel.

No more fumbling in your pockets

Digital tickets live neatly in our app, so you can just tap, scan and go.

ETicketETicket

All your tickets, all in the palm of your hand.

Calendar week image
TrainlineTrainline

Search. Book. Travel.

Looking for a cheap price?

Look no further. Compare tickets easily with our price calendar.

CalendarCalendar

We’ll find you the cheapest day to travel.

Popular in San Sebastián-Donostia

Let's do this trip right

What customers say about Trainline

Read real reviews from real users

Taking the train from Madrid to San Sebastián-Donostia in 4 hours 47 minutes

What better way to uncover the true beauty of Spain, than by zipping from its cultural centre to the coast by train? With comfortable air-conditioned carriages and a buffet car at your disposal, the reliable Renfe network is a popular way to visit San Sebastian from Madrid.

Take the direct train from city-centre to city-centre in less than five-and-a-half-hours. With the train station a mere ten minutes’ walk from the beach, in no time you’ll be knocking back sangria and eating tapas with a bayfront backdrop to boot. With around 10 trains a day serving the route, there’s nearly twice as much choice as flying. Plus, you won’t have to worry about liquid restrictions or luggage allocation with three bags per traveller allowed. Not sure where to visit first? Check out our guide on what to do in San Sebastian, as well as our favorite restaurants in San Sebastian

If you need any more information before committing to this journey, take a look at our detailed route facts below, including train times and FAQs.

Madrid to San Sebastián-Donostia by train

It takes an average of 7h 6m to travel from Madrid to San Sebastián-Donostia by train, over a distance of around 219 miles (353 km). There are normally 7 trains per day traveling from Madrid to San Sebastián-Donostia and tickets for this journey start from $23.66 when you book in advance.

First train

7:20 am

Last train

7:53 pm

Departure station

Madrid

Arrival station

San Sebastián-Donostia

Journey time

From 4h 55m

Distance

219 miles (353 km)

Frequency

7 trains per day

Changes

Direct trains available

Price

From $23.66

Train and bus operators

Renfe, ALSA

FAQs about the train journey from Madrid to San Sebastián-Donostia

Want to know more about your journey from Madrid to San Sebastián-Donostia? We've compiled some of the most frequently asked questions by our customers to help you plan your journey.

How do I travel from Madrid to San Sebastián-Donostia?

You can get from Madrid to San Sebastián-Donostia in 7 hours and 6 minutes on average, with the fastest trains taking just 4 hours and 55 minutes. Check out our Journey Planner for more details on times, tickets and prices.

How long does the train from Madrid to San Sebastián-Donostia take?

The average journey time by train between Madrid and San Sebastián-Donostia is 7 hours and 6 minutes, with around 7 trains per day running on this route. The journey time may be longer on weekends and holidays, so use our Journey Planner on this page to search for a specific travel date.

How much does the train from Madrid to San Sebastián-Donostia cost?

Train tickets from Madrid to San Sebastián-Donostia can start from as little as $23.66 when you book in advance and are usually more expensive when purchased on the day. Prices can also vary depending on the time of day, route and class you book.

What's the fastest journey time between Madrid and San Sebastián-Donostia by train?

The fastest journey time by train from Madrid to San Sebastián-Donostia is 4 hours and 55 minutes.

Madrid to San Sebastián-Donostia train times

Check out the next trains departing from Madrid to San Sebastián-Donostia for Thursday Apr 24th 2025. For the full train timetable/schedule, or to search for a later time or date, click here.
DepartsArrivesTrainDuration
7:20 amMadrid-Chamartín-Clara Campoamor12:43 pmDonostia-San SebastiánAlvia/Avant 4087 Get tickets5h 23m, direct
10:15 amMadrid-Chamartín-Clara Campoamor4:48 pmDonostia-San SebastiánAlvia/Avant 8109 Get tickets6h 33m, 1 change
12:05 pmMadrid-Chamartín-Clara Campoamor6:50 pmDonostia-San SebastiánAlvia/Avant 8129 Get tickets6h 45m, 2 changes
2:46 pmMadrid-Chamartín-Clara Campoamor7:41 pmDonostia-San SebastiánIC 4257 Get tickets4h 55m, direct
2:47 pmMadrid Atocha8:53 pmDonostia-San SebastiánAlvia/Avant 609 Get tickets6h 6m, 1 change
5:37 pmMadrid-Chamartín-Clara Campoamor10:47 pmDonostia-San SebastiánAlvia/Avant 4167 Get tickets5h 10m, direct

Renfe, Alvia and Media Distancia trains from Madrid to San Sebastián-Donostia

You can travel from Madrid to San Sebastián-Donostia on Renfe, Alvia and Media Distancia trains. When you search for times and tickets, we might also show you some other options with multiple connections or operators if they’re available.

Renfe is the national train operator in Spain. It operates trains on the longest high-speed railway network in Europe, and the second-longest in the world. The country's major cities are linked up by the high-speed AVE and Avlo trains, while other long-distance routes are served by Altaria, Talgo, Alvia and Euromed trains. Renfe also operates cross-border services into neighbouring Portugal and France. Depending on which service you are travelling on, you'll usually find two classes on Renfe trains - Estándard (Standard Class) and Confort (First Class). Fare types range from the cheapest (but least flexible) Básico fare, to the more flexible Elige fares, to the Premium fare for seats in Confort carriages.

Renfe's Alvia services combine high-speed tracks with lower speed sections, reaching speeds of up to 155 mph (250 km/h) on international lines and 125 mph (200 km/h) on conventional lines. These trains connect the cities of Madrid, Barcelona and Alicante with the other main Spanish cities. Alvia offers two types of classes – Turista (Second Class) and Preferente (First Class). The latter has wider seats, carriages with fewer seats, offers complimentary food and drinks, free newspapers, and access to parking and Club meeting rooms.

Renfe's Media Distancia are regional trains operated by CAF locomotives that run on medium-distance routes not covered by Avant high-speed trains. Most Media Distancia trains have one class. However, there are some that will have Turista (Second Class) and Preferente (First Class). These trains also have spaces for bicycles, and all seats are equipped with power sockets and reading lights.

Alvia classes from Madrid to San Sebastián-Donostia

Compare the different travel classes offered by Alvia when traveling from Madrid to San Sebastián-Donostia.

Onboard services on Alvia

Discover more about the onboard services offered on trains from Madrid to San Sebastián-Donostia.

LuggageLuggageBaggage

On Alvia trains you can take up to three pieces of baggage on board, provided that they are less than 290cm long and weigh less than 25kg in total. Strollers and instruments smaller than 30 x 120 x 38 cm are also classed as hand baggage.

RestaurantRestaurantFood and drink

Most Alvia trains have an onboard café-bar, as well as an at-seat service with a wide selection of food and drinks.

WiFiWiFiEntertainment

On board Alvia services, you can connect to PlayRenfe, a platform offering free WiFi and hours of entertainment.

ChildPassengerChildPassengerTravel with children

Children under 4 travel free on Alvia services with a free child's ticket. Plus, passengers under 14 get a 40% discount on their chosen tariff.

ModeOfTransportBikeModeOfTransportBikeBikes

With Alvia, folded bicycles that are less than 180cm long and are stored in a case count as hand baggage. If your bike is larger than this, it will count as special baggage and must be no larger than 120 x 90 x 40 cm - you must also detach the pedals and rotate the handlebars 90 degrees.

PetPetPets

You can take your pet with you if they weigh less than 10kg, travel in a carrier no larger than 60 x 35 x 35 cm, and have a pet ticket. In Elige Confort a pet ticket is free, while in Básico a pet ticket costs 25% of the price of a ticket.

WheelchairWheelchairSpecial Assistance

Alvia has an assistance service for passengers with reduced mobility or a disability. To arrange assistance, you can call (+34) 900 400 555 (international calling charges may apply).

Cheap train tickets from Madrid to San Sebastián-Donostia

The price of train tickets from Madrid to San Sebastián-Donostia starts at $23.66 one-way for a Standard Class ticket if you book in advance. Booking on the day is usually more expensive and costs can vary depending on the time of day, route or class.

Book in advance

Most of the train companies across Europe release their tickets around three to six months in advance, many of which can be cheaper the earlier you book. If you know the dates you want to travel, you may be able to find some cheaper train tickets from Madrid to San Sebastián-Donostia by booking early.§

Be flexible with your travel times

Many of the train services in Europe are also popular commuter services, lots of train companies increase ticket prices during “peak hours” (generally between 06:00 – 10:00 and 15:00 – 19:00 on weekdays). If you can, consider travelling outside of peak hours to find lower priced tickets.

Choose a slower or connecting train

On some of the busier routes, you might also have the option to take a slower or connecting train. It may take a little longer than some high-speed or direct services, but if you have a little extra time on your hands, you might find a cheaper fare. Plus, you'll have more time to enjoy the view of the countryside!

Look out for special deals

Take a look at our handy guides to find out when train operators release their special deals and offers to see if you can find cheap European train tickets for your journey.

For specific information about how to get your hands on cheap tickets, check out our European train tickets hub.

§Some train companies may not offer any Advance ticket types or cheaper deals for early bookings. On rare occasions, train companies may choose to release special offers closer to the date on last-minute or late-release tickets. This is dependent on the individual train operating company you travel with.

* Based on European average monthly visitors to Trainline’s app and website from 1.1.2023 to 10.31.2023 vs other independent retailers.

Europe’s leading train and coach app

We help customers across Europe make more than 172,000 smarter journeys every day.