How to Get from Marrakech to Fez
The most popular option is the ONCF train, taking roughly seven hours via Casablanca and Rabat — comfortable and inexpensive, but best booked ahead. A domestic flight cuts the journey to around an hour, while a private driver offers flexibility and scenic stops. Some travellers also connect the two cities via a multi-day desert tour.
Marrakech and Fez sit at opposite ends of Morocco's classic imperial-cities route, and the journey between them is a common planning question. Your choice usually comes down to a trade-off between cost, comfort, speed and the chance to see more along the way. Each option suits a different kind of traveller.
Train, Plane or Private Driver
The national rail operator, ONCF, runs the most popular connection. The train takes roughly seven hours, typically routing through Casablanca and Rabat, and is comfortable, air-conditioned and inexpensive by international standards. First class offers reserved, more spacious seating and is worth the modest extra on a long ride; booking ahead, especially in peak season, is sensible as services can fill. For those short on time, several domestic flights cover the route in around an hour, though once you factor in airport transfers and check-in the time saving narrows. A private driver is the most flexible choice, allowing door-to-door travel and stops en route, but it is considerably more expensive and the drive is long. Self-driving is possible for confident drivers comfortable with Moroccan roads and motorway tolls, though many prefer to let someone else take the wheel.
Going the Scenic Way via the Desert
Rather than travelling directly, many visitors link Marrakech and Fez through a multi-day tour that crosses the Atlas mountains and dips into the desert. A typical itinerary heads south from Marrakech over the High Atlas, pausing at landmarks such as Aït Benhaddou and the Dades or Todra gorges, before reaching the Sahara dunes near Merzouga for an overnight camp, then continuing north to finish in Fez. This turns a transfer into a genuine highlight of the trip, packing in dramatic scenery and a desert night without backtracking. The trade-off is time and pace: such tours usually run two to three days, involve long hours in a vehicle, and cost more than a simple train ticket. If your schedule allows and the Sahara is on your wish list, however, arriving in Fez by way of the dunes is a memorable way to bridge the two cities.
Quick tips
- Book ONCF train tickets in advance during busy seasons to secure a seat.
- Consider first class on the train for reserved seating on the long journey.
- Weigh flight time against airport transfers — the door-to-door saving is smaller than it looks.
- If choosing a desert tour, confirm it ends in Fez rather than returning to Marrakech.
How long does the train from Marrakech to Fez take?
The journey takes roughly seven hours, usually via Casablanca and Rabat. Exact times vary by service, so check the current ONCF timetable when booking.
Is it better to fly or take the train?
The train is cheaper and scenic but slow; flying is faster but adds airport time and cost. Many travellers prefer the train for its simplicity and value.