It's best to ditch your rental car when in Madrid as traffic and expensive parking cause headaches, though a car is handy for trips to smaller locales with limited public transportation options; many of the nation's highways radiate from Madrid including the A6 (Segovia, Salamanca, Galicia); the A1 (Burgos and the Basque Country); the A2 (Guadalajara, Barcelona, France); the A3 (Cuenca, Valencia, the Mediterranean coast); the A4 (Aranjuez, La Mancha, Granada, Seville); the A42 (Toledo); and the A5 (Talavera de la Reina, Portugal). The city is surrounded by ring roads (M30, M40, and M50), from which most of these highways are easily picked up. There are also toll highways (marked R2, R3, R4, and R5) that bypass major highways, and the A41, a toll highway connecting Madrid and Toledo.
November 2018 marked the beginning of Madrid Central, a sweeping, environmentally driven law that prohibits most vehicles—rentals included—from entering the city center. This zone is delineated by double red lines, large roadside signs, and nautilus-like "Madrid Central" logos painted clearly on the asphalt; entering without the proper permissions will result in fines. Be sure to ask your rental car agency about the specific restrictions on your vehicle as they relate to Madrid Central. Zero-emissions vehicles are not affected, so if you plan on driving in the city center, it may be worth spending the extra euros on an eco-friendly car.
Blablacar is Spain's leading rideshare app in intercity travel with more global users than Uber. Its free platform allows you to book ahead using a credit card, and message with the driver to set meeting and drop-off points. Blablacar is the most affordable way to travel to Madrid's outlying cities and beyond as drivers aren't allowed to make a profit (you essentially help the driver offset the price of gas and tolls).