If you must travel, travel safely. For contactless travel, use digital tickets on your phone.


The best prices from hundreds of train and coach companies

Join millions of people who use us every day

Travel to thousands of destinations in 45 countries

"Trainline’s take-off has been vertical. It’s the only global digital travel platform of its sort."
"For those travelling by train, the most efficient and trustworthy way to purchase tickets is Trainline."
"If you’re thinking of getting the train the best site to use is thetrainline.com."

About the journey from Madrid to Barcelona

The average train time from Madrid to Barcelona is 3h, although it takes just 2h 30m on the fastest direct Renfe Ave services. There are around 26 trains per day running from Madrid to Barcelona, the first train leaves Madrid Atocha at 06:10 and the last train leaves at 21:30.

  • All trains depart from Madrid Atocha station.
  • All trains arrive into Barcelona Sants station.

As two of the biggest cities in Spain, it’s no surprise that Madrid to Barcelona is one of our most popular train routes with locals and tourists. Whether you’re heading to Barcelona for a wander along Las Ramblas or to admire La Sagrada Familia, travelling by train means your journey starts and ends in both city centres, cutting out the hassle of airport transfers and waiting around before your flight. Travelling First Class? AVE Preferente passengers enjoy reclining leather seats and complimentary snacks along the way.

Keep reading for train times, FAQs about the journey and tips of how to find cheap train tickets. Ready to book? Search your search in our Journey Planner at the top of the page. 

Madrid to Barcelona by train

It takes an average of 3h 04m to travel from Madrid to Barcelona by train, over a distance of around 314 miles (506 km). There are normally 24 trains per day travelling from Madrid to Barcelona and tickets for this journey start from €32.30 when you book in advance.
Journey timeFrom 2h 30m
Price€32.30 - €222
Distance314 miles (506 km)
Frequency24 trains per day
Departure stationMadrid
Arrival stationBarcelona
ChangesDirect trains available
Train and bus operators

Madrid to Barcelona train times

Check out the next trains departing from Madrid to Barcelona for Wednesday 27th May 2020. For the full train timetable/schedule, or to search for a later time or date, click here.
06:10 Madrid Atocha08:40 Barcelona SantsAVE 3061 Renfe Get tickets2h 30m, direct
06:30 Madrid Atocha09:20 Barcelona SantsAVE 3063 Renfe Get tickets2h 50m, direct
07:00 Madrid Atocha09:30 Barcelona SantsAVE 3071 Renfe Get tickets2h 30m, direct
07:20 Madrid Atocha09:50 Barcelona SantsAVE 3271 Renfe Get tickets2h 30m, direct
08:00 Madrid Atocha10:30 Barcelona SantsAVE 3081 Renfe Get tickets2h 30m, direct
08:20 Madrid Atocha11:05 Barcelona SantsAVE 3283 Renfe Get tickets2h 45m, direct
08:30 Madrid Atocha11:15 Barcelona SantsAVE 3083 Renfe Get tickets2h 45m, direct
09:00 Madrid Atocha11:45 Barcelona SantsAVE 3293 Renfe Get tickets2h 45m, direct
09:30 Madrid Atocha12:38 Barcelona SantsAVE 3093 Renfe Get tickets3h 08m, direct
10:30 Madrid Atocha13:15 Barcelona SantsAVE 3103 Renfe Get tickets2h 45m, direct

Renfe and AVE trains from Madrid to Barcelona

You can travel from Madrid to Barcelona on Renfe and AVE 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 has the widest network of high-speed trains in Europe, linking major cities with AVE, AV-City, Avant, Alvia, and Euromed trains. Long-distance routes are served by Altaria and Talgo trains, while regional routes are operated by Media Distancia, Regional and Express Regional trains. Renfe also operates on international routes to France and Portugal. Renfe trains offer four different travel classes, depending on the train you’re travelling on – Turista (Standard), Turista Plus (Premium Economy), Preferente (Business Class) and Club (First Class).

AVE is Renfe's flagship high-speed service, with trains capable of reaching up to 193 mph (310 km/h). It’s one of the fastest trains in Europe and connects the main cities of Spain. Most AVE trains offer four comfort classes – Turista (standard class), Turista Plus (wider, more comfortable seats), Preferente (lounge access, wide leather seats, food and drink service) and Club (First Class equivalent, with 1-1 configuration, ultra-wide seats, gourmet food and drink and lounge access). All AVE trains have air conditioning, power sockets, free WiFi and a buffet carriage serving a selection of food and drinks.

Cheap train tickets from Madrid to Barcelona

Train tickets from Madrid to Barcelona start at €32.30 one-way for a Standard Class ticket if you book in Advance, however, if you're booking last-minute tickets on the day, the average price is around €108.08.
lowest price found
4 weeksin advance
avg. single price96.12
2 weeksin advance
avg. single price99.66
on the day
avg. single price108.08

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 Barcelona 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 guide to check when European train operators release their special deals and offers to see if you can find cheap 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.

Journey details

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

How long does the train from Madrid to Barcelona take?

The average journey time by train between Madrid and Barcelona is 3 hours and 4 minutes, with around 24 trains per day. 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 fast does the train from Madrid to Barcelona travel?

AVE high-speed trains from Madrid to Barcelona can travel at speeds of up to 193 mph (310 km/h). The fastest journey time from Madrid to Barcelona by train is 2 hours and 30 minutes.

How much does the train from Madrid to Barcelona cost?

The average train ticket price from Madrid to Barcelona usually costs around €99.66 two weeks before travel, but can start from as little as €32.30 when you book in advance. Prices also vary depending on the time of day, route and class you book.

Is there a direct train from Madrid to Barcelona?

Yes. There are 23 direct AVE trains that travel from Madrid to Barcelona each day with an average journey time of 3 hours and 4 minutes.

What time does the first train from Madrid to Barcelona leave?

The first train from Madrid to Barcelona leaves at 06:10 from Madrid Atocha. Times and services may vary during weekends and holidays.

What time does the last train from Madrid to Barcelona leave?

The last train from Madrid to Barcelona leaves at 21:30 from Madrid Atocha. Trains that depart in the early morning hours or very late evening may be sleeper services, time and services may also vary during weekends and holidays.

What's the distance between Madrid and Barcelona by train?

Trains travelling from Madrid to Barcelona cover a distance of around 314 miles (506 km) during the journey.

Which train companies operate between Madrid and Barcelona?

All trains travelling from Madrid to Barcelona are operated by Renfe – the national train operator in Spain.

Are there security checks on trains from Madrid to Barcelona?

Yes. When boarding the train from Madrid to Barcelona, all passengers must pass through a security control point for a ticket and baggage check before departure. This is a requirement on all trains in Spain and the check-point usually closes two minutes before the train is due to depart.

Looking for more information?

If you’re looking for the return train journey, check out trains from Barcelona to Madrid. If you’re looking for other options, you can also catch the bus from Madrid to Barcelona.

Our tips and tricks

We love helping our customers find inspiration for their next train journey. We also believe about taking those journeys and sharing our experiences with you, so you can sit back, relax and get the most out of your trip.

Travelling from Madrid to Barcelona on a Renfe AVE high-speed train

Review by Jaime Campoamor Velasco

With around 25 services a day, Renfe connects the two biggest cities in Spain in just 2h 30m. For the early risers, the first AVE train leaves Madrid Atocha station at 06:10 hours and the last leaves at 21:25, arriving into Barcelona Sants station at 23:55.  

Atocha station – the busiest in Spain  

Located just a few minutes from the centre of the capital, Madrid Atocha station sees around 18 million passengers pass through its doors each year. Split across several levels, and high-speed services depart from both the upper and ground floors – boarding for trains from Madrid to Barcelona is located on the upper floor.  

For my trip, I arrived at the station just after 17:00. Although my train – the AVE 3181 – left Madrid at 18:00, I decided to arrive almost an hour earlier to have plenty of time to wander around the station and pass the security check without rushing. As I was travelling on a Friday afternoon, I assumed it would be busier than usual in the centre of Madrid.  

To Barcelona in just two and a half hours  

Before I get into the details of my trip, it’s worth pointing out that although I travel a lot by train, I’d never made the journey from Madrid to Barcelona on an AVE high-speed service before. In fact, my friends and family had spent years wondering why I normally drive to Barcelona considering how far it is and how boring the A2 is – I’ve never been able to give them a good excuse.  

So, back to the review. For this trip, I brought a Promo + ticket in Turista (Standard) Plus Class that cost me just over €90. Although it may seem a lot, travelling by car between Madrid and Barcelona is quite expensive when you consider the cost of tolls and how the time you spend driving and the difficulty of parking in Barcelona adds to your fuel consumption. Plane tickets aren’t cheap either – unless you buy in advance with a low-cost airline, the price of the Iberia Puente Aereo (a dedicated Madrid to Barcelona air route) will easily exceed the cost of round-trip AVE tickets.  

I chose a Promo + ticket because the basic Renfe (Promo) fare doesn’t allow for changes or cancellations. The Promo + fare, however, cost only €7 more and allows you to cancel the ticket up to five minutes before departure by paying 30% of the total price.  

Although the Turista (Standard) seats are perfectly comfortable for this journey, I chose the Turista Plus Class (20% extra, in this case, an extra €6.85) as the seats are wider, even more comfortable and there are fewer seats in the carriage.  

Comfortable and modern trains  

All seats on AVE trains are foldable and have footrests, armrests, folding tables and two sockets for charging electronic devices. Although most of the trains offer a WiFi connection, this service is only complementary in Preferente (First) Class. If you don’t travel in this class and want to use the WiFi during the trip, you’ll have to pay for the service. There are two levels of access – Basic and Premium (you get access from three devices, movies and live TV). 

During the trip, Renfe staff offered an à la carte catering service, with a complete menu that included all kinds of drinks and food. There’s also an onboard café carriage where you can stretch your legs while you enjoy a drink.  

The AVE trains that take just 2h 30m to travel from Madrid to Barcelona (like the one I took) make no stops along the way. Other services make stops in Guadalajara-Yebes, Zaragoza-Delicia, Lleida or Camp-Tarragona before arriving in Barcelona 

Arriving into Barcelona 

After reaching speeds close to 300 km/h we arrived into Barcelona Sants station at the scheduled time, 20:30. 

Once you’re in Barcelona, ​​don't miss the impressive Sagrada Familia or the mythical Boqueria Market. Take a walk along Las Ramblas for sure, skate at one of the skateparks in the city or wander around the Raval or Borne neighbourhoods.  

About Jaime  

Jaime is one of our trusted, hand-picked travel writers. The information for this article was recorded first-hand, based on his own genuine experience of the journey. 

Continue reading
Average prices for adult tickets in economy. Discount cards and coach journey excluded. Prices are based on searches made by our customers over the past 6 months. "14 days in advance" includes days 13 and 15. / The information provided is calculated based on scheduled train services for Madrid to Barcelona for a typical week day using timetable data for 27/05/2020. On weekends, holidays or other exceptional times, fewer services may be available. The fare range provided has been found by our customers on Trainline on 01/04/2019 for travel on 01/04/2019 and for adult tickets in economy, discount cards and coach journeys excluded.

Europe’s leading train and coach app

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