The Royal High School is, by one reckoning, the 18th-oldest school in the world, with a history of almost 900 years. Historians associate its birth with the flowering of the 12th century renaissance. It first enters the historical record as the seminary of Holyrood Abbey, founded for Alwin and the Augustinian canons by David I in 1128.
The Grammar School of the Church of Edinburgh, as it was known by the time Adam de Camis was rector in 1378, grew into a church-run burgh institution providing a Latin education for the sons of landed and burgess families, many of whom pursued careers in the church.
In 1505 the school was described as a high school, the first recorded use of this term in either Scotland or England. In 1566, following the Reformation, Mary, Queen of Scots, transferred the school from the control of Holyrood Abbey to the Town Council of Edinburgh. James Lawson was a big influence in building work for the school in 1578 and from about 1590 James VI accorded it royal patronage as the Schola Regia Edimburgensis, or King's School of Edinburgh.
In 1584 the Town Council informed the rector, Hercules Rollock, that his aim should be "to instruct the youth in pietie, guid maneris, doctrine and letteris". As far as possible, instruction was carried out in Latin. The study of Greek began in 1614, and geography in 1742. The egalitarian spirit of Scotland and the classical tradition exerted a profound influence on the school culture and the Scottish Enlightenment.
The Romantic era at the turn of the 19th century was for Scotland a golden age of literature, winning the Royal High School an international reputation and an influx of foreign students, among them French princes. The historian William Ross notes: "Walter Scott stood head and shoulders above his literary contemporaries; the rector, Alexander Adam, held a similar position in his own profession." By the end of the Napoleonic Wars, an old scholar remembered, 'there were boys from Russia, Germany, Switzerland, the United States, Barbadoes, St. Vincent, Demerara, the East Indies, besides England and Ireland.' The Royal High School was used as a model for the first public high school in the United States, the English High School of Boston, in 1821.
Learning Greek ceased to be compulsory in 1836, and the time allotted to its study was reduced in 1839 as mathematics became recognised. The curriculum was gradually broadened to include French (1834), after-hours fencing and gymnastics (1843), German (1845), science (1848), drawing (1853), military drill (1865), English (1866), gymnastics as a formal subject and swimming (1885), music (1908), and history (1909). In 1866 classical masters were confined to teaching Latin and Greek. A modern and commercial course was introduced in 1873. A school choir was instituted in 1895.