History of rail transport in Morocco
Rail transport in Morocco was initially developed during the protectorate. It functioned primarily as a means to mobilize colonial troops and to transport natural resources. Later, a standard-gauge network was built.
First narrow-gauge lines
First 600 mm (1 ft 11 5⁄8 in) line
The first short narrow-gauge railway in Morocco was a narrow-gauge line presented to the Sultan of Morocco in 1887 by the Belgian Government to connect his palace with his Jardin l'Agdal de Meknes. With the railway came two coaches and one steam locomotive delivered via F. Weidknecht, Paris. This move was done to improve the Belgian trade possibilities with the Sultan with hope to build railways in Morocco.Narrow-gauge railways in former French Morocco
In 1907, the French Compagnie Marocaine established a line connecting the Port of Casablanca to a quarry in Roches Noires with a Decauville engine, though it was destroyed by tribesmen of the Shawiya.The first major French-built narrow-gauge railway line in Morocco was completed in 1908 with minimum-gauge track, which was later converted to narrow-gauge track. More lines utilizing gauge track followed. Beginning in 1912 and ending in 1935, French Morocco had one of the largest gauge networks in Africa with a total length of more than 1700 kilometres. After the treaty of Algeciras where the representatives of Great Powers agreed not to build any standard-gauge railway in Morocco until the standard-gauge Tangier–Fez Railway being completed, the French begun to build military gauge lines in their part of Morocco.
The 948 km Marrakesh – Casablanca – Kenitra – Fez – Oujda line became known as Chemins de fer strategiques du Maroc and the branch lines diverting from the line as Chemins de fer de penetration du Maroc. These lines were mostly built – with exception of Guercif – Outat Oulad el Hadj – Midelt, which was started in 1916 and completed in 1920 – during the period of 1921–1925.
Railways in former Spanish Morocco
There have been narrow-gauge railways which used meter gauge, gauge, and gauge in former Spanish Morocco.A narrow-gauge railway was also constructed from Tetuan to Ceuta in 1913–1918 by CEC. It was handed over to the state-run FCM in 1942 and closed in the aftermath of the Moroccan independence.
Standard-gauge railways
Before the independence of Morocco in 1956 four standard-gauge railways were built by individual companies. In 1963 all four were merged to form the ONCF, Morocco's current national railway operator.Railways of Morocco
Railways of Morocco was established in 1920 and built two railway lines:- Casablanca to Kenitra and Sidi Kacem, completed in 1925
- Casablanca to Marrakesh railway, completed in 1936.