The Regius Chair of Astronomy is one of eight  Regius Professorships at the  University of Edinburgh, and was founded in 1785. Regius Professorships are those that have in the past been established by the  British Crown, and are still formally appointed by the current monarch, although they are advertised and recruited by the relevant university following the normal processes for appointing a professorship.
 The Regius Chair of Astronomy in Edinburgh is unusual because of its relationship with the position of the Astronomer Royal for Scotland, and the  Royal Observatory Edinburgh (ROE). Between 1834 and 1990, the Regius Professor at the University, the Astronomer Royal, and the Director of the Royal Observatory were all the same person. This is no longer true however, as explained  under "New Structure" below.
 Astronomy was originally taught in Edinburgh by the Chairs of Mathematics and of Natural Philosophy. 
A Chair of Practical Astronomy was established in 1785 by a Royal Warrant signed by George III. The first holder was  Robert Blair, who held the position until his death in 1828. However, he was never provided with an observatory or any instruments, and refused to do any teaching, seeing the position as a sinecure.
At that time, the Royal Commission was reviewing Scottish Universities and recommended that the chair should not be filled 'until a suitable observatory... could be established' 
 Meanwhile, outside the University, the  Edinburgh Astronomical Institution, a club of private individuals, had succeeded in building an observatory on Calton Hill in a new building designed by  William Playfair. In 1822 the Institution presented a loyal address to George IV, resulting in the observatory being granted the title of Royal Observatory. After considerable delay and negotiation, in 1834  Thomas Henderson was appointed as both the first Astronomer Royal for Scotland and the second Regius Professor. He remained in both positions until he died in 1844. Thomas Henderson's main claim to fame is being, along with  Friedrich Bessel, the first astronomer to measure the  parallax of a star, and hence a reliable stellar distance. He made his measurements at the  Cape of Good Hope and reduced the data after taking up his position in Edinburgh.
 In 1846  Charles Piazzi Smyth became Regius Professor and Astronomer Royal, and held both positions until he retired in 1888. He was the first Regius Professor to actually provide lectures in Astronomy, sixty five years after the founding of the chair.
Piazzi Smyth had a long and full career, including the establishment of a public time service via the Time Ball and the One O'Clock Gun, the exploration of the idea of mountain top astronomy, the investigation of the spectra of the Sun, the Zodiac and the Aurora, and innovative developments in photography.
Later in his life he became obsessed with mystical interpretations of the Pyramids.
 Following the retirement of Piazzi Smyth, both the future of the Royal Observatory and the Regius Professorship were once again thrown into uncertainty by a Royal Commission on Scottish Universities, until the generous gift of Lord Lindsay led to the creation of a new Royal Observatory building on Blackford Hill (see  for extensive detail), and  Ralph Copeland  was appointed as fourth Regius Professor and third Astronomer Royal. Copeland was well known for spectroscopic observations of planets, comets, and nebulae, and was the first person to observe Helium outside the Sun. He also carried out extensive travel, both to observe transits of Venus, and to continue Piazzi Smyth's researches into mountain top astronomy.
 Copeland died in 1905 and was replaced both as Regius Professor and as Astronomer Royal by  Frank Dyson. He was the first Regius Professor whose title was simply "Chair of Astronomy" rather than "Chair of Practical Astronomy". He investigated the spectrum of the solar corona and chromosphere. In 1910 he left to become Director of the Royal Greenwich Observatory and (English) Astronomer Royal - the only astronomer to have held both Astronomer Royal positions. He later became famous for organising eclipse expeditions which helped to proved Einstein's General Relativity Theory, and for instigating the transmission of the "pips" from the Greenwich Observatory to the BBC.
 In 1910 Dyson was replaced by  Ralph Sampson. Before coming to Edinburgh Sampson was well known for pioneering work on the colour temperature of stars, and a theory of the motions of the Galilean satellites. After his appointment, his work took a very practical turn, aiming at producing a more accurate time service, improving the optical performance of telescopes, and developing a recording microphotometer and techniques for performing spectrophotometry of stars. He also led the construction of 36inch telescope which still sits in the East Tower of the ROE. Sampson retired in 1937, to be replaced by  W.M.H. Greaves in 1938. Greaves kept the national time service going the war, and led extensive work on determining the temperatures of stars, and the physical properties of their atmospheres, using spectrophotometry, as well as studies of the effect of sunspots in terrestrial magnetism. He died suddenly in 1955, and was replaced as both Regius Professor and Astronomer Royal by  Hermann Bruck.
 During the 1960s and 1970s, the ROE underwent considerable expansion, so that technical and scientific contributions are properly seen as due to a whole community. Nonetheless, it is possible to discern clear themes in the leadership of successive astronomers.
 Hermann Bruck was the most important historical figure for Edinburgh astronomy, at least in leadership terms. When he arrived in 1957 the observatory had six scientific staff. By the time he retired in 1975, there over a hundred, and the observatory was established as a major international centre. There were three main themes to his leadership. The first, together with his wife Mary Bruck (nee Conway) was the creation of the first full Astrophysics degree, and the expansion of first year astronomy teaching to large classes of students from many disciplines. The second theme was automation - both computerised data reduction, and the creation of automated measuring machines, which led to a sequence of machines which scanned and digitised photographic plates - GALAXY, COSMOS, and SuperCOSMOS. The third theme was the development of mountaintop overseas observatories, fulfilling the dreams of Piazzi-Smyth. This work began with the creation of a station at Monte Porzio in Italy, followed by the design of a Northern Hemisphere Observatory in La Palma (which was then implemented by the Royal Greenwich Observatory), the building and operation of the UK Schmidt Telescope in Australia, and finally the building and operation of the infra-red specialised UK Infrared Telescope (UKIRT) in Hawaii. Bruck retired in 1975.
 The next holder of both the Regius Professorship and the Astronomer Royal position was Vincent Reddish, who had been at ROE since the 1960s, and in fact was to a large extent responsible for many of the advances in the Bruck era - automation, systematic sky surveys, and the creation of the  UK Schmidt Telescope and UKIRT. He resigned in 1978 and concentrated on his controversial private researches into dowsing.
 Malcolm Longair was appointed to the joint position in 1980, and continued the trends started by Bruck and Reddish of making the Royal Observatory Edinburgh a centre of astronomical technology and sky survey work. Under Longair's leadership the ROE created a radical new facility, the James Clerk Maxwell Telescope (JCMT), and built a series of ground breaking instruments for both ground-based and space-based instruments. University leadership in Astronomy was however largely delegated to Mary Bruck and Peter Brand, under whom the Department of Astronomy merged with the Department of Physics, and was re-named the Institute for Astronomy. Longair resigned in 1990, during a difficult period of political discussion over the structure of British Astronomy, and moved to the Cavendish Laboratory in Cambridge.
 Developments since 1994 here.
 Here "ARn" refers to the holder also being the n'th  Astronomer Royal for Scotland. In al those cases, the date of holding the Astronomer Royal position are the same as for holding  the Regius chair.