Best Train Routes in Morocco

Sep 16, 2026

5 MIN READ

High-speed trains in Tangier, Morocco. Mounir Taha/Shutterstock

Two silver trains are side by side at an outdoor train station during the daytime. A clock shows 1:20.

I moved from the UK to Morocco in 2018 to connect deeper with the ocean and my passion, surfing. Nowadays I am happy to call Taghazout home; it's the perfect playground for me, with multiple surf and yoga spots, and a charming village with a grounded community choosing a simple life in tune with the ocean. To be able to balance this surfing life with explorations for Lonely Planet – be it hiking in the Atlas Mountains or delving into Moroccan and European cities – is a dream come true.

Lonely Planet may earn a commission from affiliate links on our site. All recommendations and reviews reflect our own independent opinions.

Morocco’s passenger train routes were originally built under the French protectorate in the 1920s. While major city stations have been upgraded over the years, Casablanca Voyageurs, Rabat Ville and Gare de Marrakesh have retained some of their original art deco charm. In contrast, Tangier Ville, Gare de Fes and Rabat Agdal, with their modern architecture, reflect Morocco’s ambitious investment in rail travel and bold expansion plans to move people around for the 2030 FIFA World Cup and beyond. 

Morocco’s rail network is centered in the north of the country, and its star is Al Boraq, Africa's first high-speed rail service. This pointy-nosed train links Tangier and Casablanca (337km) in 2 hours and 10 minutes, reaching top speeds of 320km/h. Plans are underway to extend the Al Boraq line from Casablanca to Marrakesh, with completion expected by November 2029, and eventually further south to Agadir.   

Since moving here in 2018, I’ve experienced many of Morocco’s best train routes, from the "blink and you’ll miss it" Al Boraq to the slow-rolling overnight sleeper train from Tangier to Marrakesh. While Morocco’s rail travel is still relatively undiscovered by international visitors, don’t let that stop you: it’s comfortable, easy to use, reliable, scenic and – for solo travelers especially – excellent value for the money. 

To continue planning your trip to Morocco, download the Lonely Planet app or check out our Morocco guidebook.

1. Casablanca to Tangier (Al Boraq)

Best for high-speed travel

Boats in the water; a tall tower is on the right shore in the distance.
Mohammed VI Tower on the Bouregreg waterfront in Rabat, Morocco. Ahmed El Honsali/Shutterstock

Africa’s fastest train line runs regularly (every hour) between Casablanca and Tangier, with stops in Rabat Agdal and Kenitra (you can board and disembark at both). The total journey time is 2 hours and 17 mins (by road, it takes just under 4 hours, depending on traffic). Al Boraq’s silver exterior and pointed nose give it a futuristic, streamlined look. The double-decker seating inside is spacious, and there are laptop (or dining) tables, charging sockets, air-conditioning, clean toilets and free wi-fi. Tuck into the train's onboard dining menu.

From Casablanca to Kenitra, Al Boraq travels fast enough to let you enjoy the outskirts of Casablanca and the journey through Rabat (look for the new Mohammed VI Tower, Morocco’s tallest tower, on the left as the train crosses the Bouregreg River). Then the train picks up speed, reaching 330km/h between Kenitra and Tangier.

Booking tip: The Al Boraq trains stop at Casablanca Voyageurs and Rabat Agdal. If you search at ONCF for tickets starting from Rabat Ville, results will return only a regional train instead of Al Boraq.

Planning tip: Check prices for 1st and 2nd class; depending on seat availability, it’s sometimes just 5-10% extra to upgrade. You’ll get more space, and 1st class gives you access to the Al Boraq lounge at the station.

2. Tangier to Marrakesh

Best sleeper train

A narrow brick passageway between buildings with blue accents and plants.
Tangier's kasbah. Eros Rigoli/Shutterstock

When I discovered there was an overnight train from Tangier to Marrakesh, I was excited – it’d been years since I enjoyed that style of travel! While simple, it delivers an experience. The night train departs Tangier at 23:45. Book a couchette and you’ll be in one of a handful of four-berth cabins. Inside, two narrow bunk beds and thin mattresses are basic and dated, but the antique floral wallpaper adds a touch of cozy chintz. Clean sheets, a pillow and a blanket are provided. There’s a dim light and a small space above your feet to store luggage.

The train travels slowly, so there’s a chance you’ll be lulled to sleep by the rolling and wake up shortly before arriving in Marrakesh's station at 9:23, both in time for breakfast and feeling a little smug that your night’s sleep and 560km classic train journey cost about 370 Moroccan dirham (Dh). 

Another sleeper train runs west to east from Casablanca Voyageurs (departs 21:07) to Oujda, a small Moroccan city near the Algerian border. Tickets are Dh370 for a couchette.

Booking tip: There is occasionally some confusion about whether the sleeper train still operates, so it is best to book a couchette in person at any train station ticket office.

Planning tip: If you are traveling in winter months, take an additional blanket or warm layers. A trolley service serves snacks and drinks on board; have cash to spend. You can travel between Tangier and Marrakesh on the day trains as well.

3. Casablanca Airport to Casa Port

Best to the city center

The rooflines of white buildings with signage in red and green.
Casablanca's historic center. mehdi33300/Shutterstock

For flights arriving and departing in Casablanca, it may be helpful to know that the train station is located in the basement of the arrivals terminal. Solo travelers and those who arrive during rush hour may rather avoid the cost of a taxi and the hassle of navigating Casablanca's traffic by hopping on this hourly service. The train from the airport to Casablanca Port, where you can walk (or take a short taxi ride) to city center hotels, is direct and takes 60 minutes. 

Booking tip: For online bookings at ONCF, search for travel to or from MED V Airport (the abbreviation for Casablanca International Airport train station). A one-way 1st-class ticket costs Dh80; second class is Dh60. 

Planning tip: From the arrivals area, take the elevator or escalator down to the basement (level 1) of terminal 1.

4. Fez to Marrakesh (Al Atlas)

Best heritage route

Spring flowers in grassland with rocky low peaks beyond.
The northern Moroccan countryside outside Meknes. A John Russell/Shutterstock

This regular Al Atlas train threads between Morocco's two great imperial cities; the cross-country service takes 7 hours direct. Departing from Fez, the old-school train traverses farmlands, olive groves and traditional hamlets, with stops including Meknes, Rabat and Casablanca. Around Rabat, the scene shifts from rural scenery to urban cityscapes, then to industrial areas on the outskirts of Casablanca. As you get closer to Marrakesh, it becomes more arid and barren, with low ridges and burnt orange hills on the horizon. 

Booking tip: Book your journey online with ONCF, and check that it’s the direct service. Single-journey tickets cost from Dh200 in second class and from Dh350 in 1st class; 2nd class is in open carriages, with some eight-seater compartments. Seating in 1st class is in six-seat compartment carriages with air-conditioning, facing your fellow travelers, which can spark interesting conversations and offer a glimpse into other travelers' habits.

Book your Morocco trip with Lonely Planet Journeys

See Morocco how it's meant to be seen

Planned by local experts and tailored to you, Lonely Planet Journeys handles the logistics so you can just enjoy the trip. Tell us what you want and we'll build your Morocco itinerary from scratch, or browse our bookable trips to get inspired.

Explore related stories