How to Train From Casablanca to Marrakech

Last Updated on July 29, 2025

Taking the train from Casablanca to Marrakech is a fun and scenic experience! The trip is less than 3 hours, and along the route you’ll have beautiful views of mountains, valleys, and desert landscapes.

While I visited Morocco, I used the train system to travel from Fes, to Casablanca, to Marrakech. I found the Moroccan train system is a very reasonably priced, safe, and comfortable mode of transportation in Morocco

a busy street in marrakech morocco
A busy street in the Marrakech medina.

How to Train From Casablanca to Marrakech: The Basics

To take the train from Casablanca to Marrakech, you’ll use ONCF. ONCF (Office National des Chemins de fer du Maroc) is Morocco’s national railway company. It provides an extensive and reliable train network that connects major cities and tourist destinations across the country. You can use ONCF to get to Fes, Tangier, and other cities, too.

Casablanca to Marrakech Railway Route

The Al Atlas train, which runs from Casablanca to Marrakech, is a great option for traveling between these two Moroccan cities. Trains from Casablanca to Marrakech run regularly throughout the day, from about 9:00am to 7:00pm. There’s typically a train going every hour. 

Train Stations in Casablanca

Casablanca has two major train stations. Casa-Port is a station near the harbor which serves the urban tram network and suburban trains. If you’re visiting Casablanca, you might use this station for getting around the city. 

Casa-Voyageurs is the city’s primary train station, and a major transportation hub for the region. This train station is in the center of Casablanca, and it’s here that you’ll catch the train from Casablanca to Marrakech. 

Casa-Voyageurs is where both domestic and international train services depart. The station has all the important amenities including waiting areas, ticket counters, restrooms, shops, and restaurants.

Train Stations in Marrakech

Marrakech has one main train station called Marrakech Railway Station (Gare de Marrakech in French). It is located near the city center, which makes it easily accessible to both locals and tourists. The drive from the station to the old Medina of Marrakech is about 15 minutes. 

Marrakech Railway Station has plenty of amenities, including ticket counters, waiting areas, restrooms, and a luggage storage facility. There are also shops, cafes, and restaurants where you can grab a meal or refreshments. 

the front of Marrakech train station, where you will arrive if you take the train from Casablanca to Marrakech
The Marrakech train station.

How to Book a Train Ticket from Casablanca to Marrakech

You can buy your ONCF train tickets in person, or online. You can get information on timetables and prices on the ONCF website.  

You have the option to book through the website using a credit card – this is what I did. The site is only in French and can be a bit buggy, but it does work. Just open up Google Translate to help get you through the checkout process if, like me, your French isn’t strong. 

You also have the option of buying your tickets at the train station. Head to the nearest train station to book. In advance is always best (especially if you want to book first class). In the station you can pay by credit card or by cash. 

If you’re okay with economy class, you can usually buy a ticket the day of. Most train routes run regularly so it’s rare to have every seat sold out. That said, if you want to guarantee your train time, book in advance.  

If you buy your ticket through the website, you can download the PDF of the tickets to print them or show them on your phone when boarding a train. If you buy your ticket in the station, you’ll be given a printed ticket. I opted to download the PDF on my phone, which worked perfectly for boarding the train. 

Casablanca to Marrakech Train Ticket Prices

How much you pay for your ticket from Casablanca to Marrakech will vary based on when you’re traveling (weekend or a weekday), how in advance you book your tickets, and what class you book. 

Typically, a train ticket from Casablanca to Marrakech in Economy Class will start at around $15 USD per ticket. First Class seats cost about $18 USD per ticket.

a woman boarding a train on the platform in Fes Morocco.
Boarding an ONCF train in Fes, Morocco.

ONCF Train Classes: Economy Class Vs. First Class

Every train in Morocco is divided up into compartments, and there are two classes to choose from. If you’re only traveling on the train for a few hours, the class you book isn’t really a big deal. Both economy and first class are clean and comfortable.

ONCF Economy Class

In ONCF economy class, you’ll find rows of seats, or compartments that have 8 seats in each. The seats are clean and comfy. Economy class cars have restrooms and places to stow your storage. When you book an economy class ticket, you won’t have a reserved seat. You’ll just find whatever seat is free. 

ONCF First Class

In first class on ONCF, you’ll have all the same perks as economy class. The main differences are that seats are a bit bigger (compartments have only 6 seats), and you’re able to reserve a seat. If you’re traveling in a group of 2 or more, reserving a seat is a nice perk because it ensures you’ll get to sit together. 

Inside a first class cabin on the train from Casablanca to Marrakech.
Inside a first class cabin on the train from Casablanca to Marrakech.

Amenities on The Train From Casablanca to Marrakech

The train from Casablanca to Marrakech has all the amenities you need. There are train attendants available to assist you in boarding the train, finding your seat, and helping with any questions you may have.

The trains have clean washrooms, and plenty of storage space for stowing your luggage. All cars have air conditioning, so you’ll be comfortable the whole trip.

ONCF trains typically offer a trolley. It will come around offering tea, coffee, sandwiches, and snacks for purchase. Just note that during Ramadan, the trolley service isn’t available. 

It’s best not to snack or drink beverages (including water) on the train from Casablanca to Marrakech during Ramadan, if you’re traveling during daylight hours.

Most local people around you will be fasting, and as a guest in Morocco, it’s respectful to follow suit and refrain from eating or drinking. The trip from Casablanca to Marrakech isn’t long, so just be sure to have a meal and drink lots of water before you board the train. This one simple thing helps you to be a more responsible tourist!

Traveling all over Morocco? Here are the travel times for the train from Casablanca to Marrakech, and other popular Morocco train routes. 

Morocco Train RouteTravel Time
Casablanca to Marrakech2 hours 45 minutes
Marrakech to Fes6 hours 30 minutes
Casablanca to Fes3 hours 50 minutes
Marrakech to Rabat4 hours 
Rabat to Fes3 hours 
Tangier to Marrakech 5 hours 15 minutes
Tangier to Casablanca2 hours 10 minutes
Casablanca to Casablanca Airport32 minutes
A hallway and door inside the ONCF train traveling from Casablanca to Marrakech.
A hallway inside the ONCF train traveling from Casablanca to Marrakech.

Morocco Train Travel FAQs

Let’s dive into some of the most common questions about how to train from Casablanca to Marrakech. 

Can you travel around Morocco by train?

Yes, you can travel around Morocco by train. Morocco has an extensive railway network that connects major cities like Casablanca, Marrakech, Fez, and Tangier. The trains are a comfortable and convenient way to get around, and see Morocco’s diverse landscapes. While the train system doesn’t cover the more remote areas of Morocco, it’s a popular choice for many visitors traveling between cities.

Is the train system in Morocco good?

The train system in Morocco is great! Train travel is a reliable and comfortable mode of transportation between major cities and urban centers throughout Morocco. The trains are well-maintained, safe, and affordable. However, the Morocco train system doesn’t extensively cover remote areas. 

Is there a train from Marrakech to Casablanca?

Yes, there is a train connection between Marrakech and Casablanca. This route is one of the most popular train journeys in Morocco, and the train service is safe, efficient, and comfortable. Trains run regularly throughout the day (almost every hour) and the trip between Marrakech and Casablanca takes just under 3 hours. Tickets in economy and first class are available, for a reasonable price.

How long is the train trip from Casablanca to Marrakech?

The train trip between Casablanca and Marrakech is typically around 2 hours and 45 minutes to 3 hours, depending on the specific train service and stops along the way. This route is one of the busiest and most well-connected in all of Morocco, and so trains run regularly throughout the day. 

Is it safe to travel by train in Morocco?

Train travel in Morocco is very safe. Traveling by train is something that Moroccans regularly do. I noticed families, single women, business travelers, and solo travelers on board. There’s also plenty of helpful guards, train agents, and police at stations and on board the trains. 

a mosque in marrakech surrounded by lush greenery and people walking
The Koutoubia Mosque in Marrakech

Train Travel in Morocco: Casablanca to Marrakech

Traveling from Casablanca to Marrakech by ONCF train is an easy and comfortable way to get between these two beautiful cities. Train ticket prices are super reasonable, and the trains are efficient and fast. 

Aside from those benefits, I personally really enjoyed the train from Casablanca to Marrakech because the views of the Moroccan countryside are amazing. It was also a great way to interact a bit with local people. If you’re traveling between cities in Morocco, the train is the way to go. 

More from Pina Travels on Morocco: