A 500-year-old medical textbook has finally found its way back to Dublin’s Marsh’s Library having been lost for more than a century.

It was bought along with an antique mirror for €90 from a Dublin junk shop by an unnamed barrister and returned to the library last Friday. Dr Jason McElligott of the library described the find as “gold dust”.

Originally published in 1538 in Basle, Switzerland, the book is the third volume in a series of five on the medical works of physician, philosopher and surgeon Galen.

Dr McElligott told The Irish Timesthat the book had been part of the library’s collection since its foundation in 1701.

The volumes were previously owned by the 17th-century English physician and scholar Theodore Gulston, who set about improving on Galen’s works by updating them and making the text clearer for students.

The book in question is heavily marked with annotations and even has slips of paper held in place with a needle containing Gulston’s notes on the text.

“In terms of scholarship and learning it is absolutely priceless,” Dr McElligott said.

“What we have is a very important medic in the history of medicine working through his thoughts as he’s working through the work of Galen.

“Throughout the book there are notes to himself . . . he put a slip of paper and pins it in with a needle – the 17th century equivalent of a thumbtack – so for historians and academics this is like gold dust.”

Dr McElligott said Archbishop Narcissus Marsh bought or was donated the book some time before coming to Dublin in 1679 and it formed part of the library’s original collection.

Although Marsh’s was the first public library in Ireland, books have never been lent out and Dr McElligott said a “significant” medical text like this would have been kept locked away even when it disappeared more than 100 years ago.

When the book was returned on Friday – wrapped in a copy of The Irish Times– Dr McElligott said he knew “within a few seconds it was the missing copy”.

The barrister who returned the book said it had reached the junk shop following a clearance of a house in Dublin 4.

Dr McElligott said the library was very grateful to have the book back and it was complete luck that somebody with a knowledge of books thought “hang on, that doesn’t belong in a junk shop”.

He described the unnamed barrister as a “complete gentleman and a scholar” before adding: “What was particularly impressive is he declined all offers of a reward – all he wanted to do was do the right thing.”