Purchase your train ticket at the nearest station in Morocco. Ask the airport or hotel staff. You can not buy a ticket ahead of time outside the country. You can get your ticket a day or two ahead of your planned trip, however. The trains run frequently, so there is always another going in your directions if you miss the one you planned on. The hotel staff can hlp you book a particular train trip for you, and you may receive your tickets when you arrive at the station.
Decide if you want to travel first or second class. The difference is the number of people in each class. The train is divided into compartments with six people in the first-class compartment and eight people in second. So, it’s a bit less crowded in first class. The difference in price is only about $15.
Try to plan your trips so you will be in the location you wish for the night. Know the approximate time for each train ride, then schedule your time in each location. Plan for a three-hour ride from Marrakech and Casablanca. It will take four hours from Marrakech to Rabat and seven hours from Marrakech to Fez.
Always bring bottled water when you are traveling in Morocco. With all the foot travel you will be doing, it’s easy to get dehydrated. It doesn’t hurt to keep a snack with you also. However, the train does offer refreshments from a cart that makes its way through the train. They will offer drinks, sandwiches and other snacks. However, if traveling during the Muslim holiday of Ramadan, in which the religious fast until sundown, you must bring your own food.