The Royal Palace of La Granja de San Ildefonso (Spanish: Palacio Real de La Granja de San Ildefonso), known as La Granja, is an early 18th-century palace in the small town of San Ildefonso, located in the hills near Segovia and north of Madrid, within the Province of Segovia in central Spain. It became the summer residence of the Kings of Spain from the 1720s during the reign of Philip V. The palace is in a restrained Baroque style, surrounded by extensive gardens in the formal Jardin à la française style with sculptural fountains. It is now open to the public as a museum. History The area was a favourite hunting grounds for many Castilian kings, due to its location on the forested northern slopes of the Sierra de Guadarrama. In the 15th century, Henry IV of Castile built the first hunting lodge on the site, along with a small shrine dedicated to San Ildefonso (saint Ildephonsus of Toledo), which gave this place its first name. Isabella I of Castile granted both buildings to the monks of the Santa Maria del Parral monastery in Segovia, who built an almshouse and developed a granja (farm) alongside the lodge and shrine. Palace The site was purchased from the monks in 1719 by King Philip V, after his summer palace nearby at Valsaín burned to a shell. He was the first Spanish king from the French Bourbon dynasty. Beginning in 1721, Philip began building a new palace and gardens modeled on Versailles, built by his grandfather, Louis XIV of France. Like Versailles it embraced a cour d'honneur on the approaching side, and formal gardens, with a main axis centred on the palace, that were surrounded by woodland in which further hidden garden features were disposed. Like Versailles, La Granja began as a retreat from the court but became a centre of royal government. For the architect, Philip began with an unpretentious project by the Spanish architect Teodoro Ardemans, incorporating a chapel centred on one facade, which was enlarged in a second phase, ca 1728-34 under Andrea Procaccini and Sempronio Subisati, who provided the courtyards in the flanks, then given its definitive character by Filippo Juvarra, who was brought from Turin, based on recommendations in the circle of Philip's second queen, Elizabeth Farnese of Parma, and his assistant, Giovanni Battista Sacchetti. When the King decided to abdicate in 1724, his intention was to retire