One can take the train or the bus. Autocares Herranz has buses from 2 stations. At #10 Calle Isaac Peral, departures are at 8, 10 AM, 2, 5:30 PM. At #7 Paseo de Moret, departures are at 9, 11 AM and 1, 3 PM. From El Escorial, the same line goes to the Valley of the Fallen. Trains leave from Atocha Station starting at 8 AM nearly every hour. El Escorial is 30 miles from Madrid and trip takes about 1 hour by train. If you're not a "do it yourselfer" you can take a 1 day tour to both places, or better still, a one day tour... which can be arranged by your hotel. Unless you're driving, the tours are easier.
El Escorial (The Royal Monastery of San Lorenzo del Escorial)
This huge granite fortress houses a wealth of paintings and tapestries, and serves as a final resting place for Spanish kings. It is made foreboding both inside and out, by its sheer size and institutional look. Taking 21 years to complete, El Escorial boasts 1200 doors, 2593 windows, 300 cells, and contains more than 1600 paintings, including works by El Greco, Velasquez, Bosch, Titian, and Tintoretto.
Because the palace is so vast, you simply can't see it all. Do see the New Museo, which is the picture gallery. Philip II collected most of the paintings. The Royal Library contains a priceless collection of books and is one of the most significant libraries in the world. The Phillip II Apartments contain the "cell for my humble self" built by the religious Phillip. It overlooks the altar. The throne room is very simple. The Apartments of the Bourbon Kings are lavishly decorated. The Royal Pantheon, under the altar of the church is where you'll find most of the kings, queens buried. Nearby, on a lower floor, is the "wedding cake" tomb for children. Watch what you say in the Whispering Hall.
If time permits, you might also visit the Casita del Principe, a small but elaborately decorated 18th century palace that was a hunting lodge. It's almost impossible to visit the monastery and the cottage in the morning, but most visitors don't mind missing the cottage. Visiting hours of El Escorial: In summer 10-1, 3:30-6.
The Valley of the Fallen
This architectural marvel took two decades in the making, and is often referred to as Franco's Escorial. It is dedicated to those who died in the Spanish Civil War. Here, a gargantuan cross, nearly 500 feet high, dominates the Rock of Nava, a peak of the Guadarrama Mountains. The funicular to the foot of the cross is well worth the small fee. Directly under the cross in a basilica in mosaic, the body of Jose Antonio, the founder of the Falangist party, is buried. Franco is also buried here. On your way to the basilica, you'll walk through six chapels. It's like going through a huge tunnel to the center of a mountain. The Valley of the Fallen Monument is open from 10-7 daily.