Autopista de Circunvalación M-40

The M-40, in Spanish transport, is a Madrid orbital motorway. It is the second-outermost of the Madrid orbital highways, the M-30 being the closest to the centre of Madrid. It surrounds 17 out of the 21 districts of Madrid and the contiguous town of Pozuelo de Alarcón. In terms of length and surface surrounded, it may be compared to London's North and South circular roads, or Paris' A86 super-périphérique.

Overview
The M-40 is the second highway belt of Madrid and was built between 1989 and 1996. It has a total length of 63.3 km, looping around Madrid and its suburb Pozuelo de Alarcón at a mean distance of 10.1 km to the Puerta del Sol. The actual distance is much closer in the southern and eastern spans, which have been engulfed by the city in some points; than in the west, where the Casa de Campo and the projection towards Pozuelo brings it further from Madrid itself.

Furthermore, it is the only one of the several ring roads serving Madrid that runs as a full-fledged motorway for all its length: a span about 2 km long at the northern arc of the inner M-30 are not freeway-grade, having level crossings and traffic lights; while the outermost M-50 is not a full ring road due to the interruption caused by the Mount of El Pardo protected natural zone. With the "normal" M-40 traffic already being one of the heaviest in Spain, this provides for mighty jams in its northern span during peak hours. The Madrid regional government, which built the M-45 motorway external to the M-40 specifically to decongest the southern and eastern spans of the older beltway, has recently aired plans to address the northern jams by effectively "closing" the M-50 ring with a tunnel under the protected area.

Somewhat counterintuitively to foreigners and natives alike, the M in the road name does not indicate a hypothetical ownership of the road by the autonomous regional administration. Instead, both the M-40 and the M-50 are state-owned freeways, as shown by the white text on blue background of their signals, whereas Madrid regional motorways like the M-45 use black text on an orange background that identify them as pertaining to the "regional first order roads" category of the Spanish Traffic Code. The M-30, on the other hand, is managed by the Madrid City Council as an urban freeway.