Da Vinci (1452 - 1519) filled hundreds of pages of notebooks with detailed studies of organs, bones, vessels and muscles using new illustrative techniques.
Curators say his work foreshadows modern techniques like MRI scans and 3D computer modelling "to an astonishing degree".
Almost 500 years after his death, pages of his anatomical notebooks are going on display alongside 21st-century medical imagery in the exhibition Leonardo da Vinci: The Mechanics of Man at The Queen's Gallery, Palace of Holyroodhouse.
Da Vinci began researching the human body to ensure his paintings were as true to nature as possible. Between 1507 and 1513 he dissected more than 30 human corpses, including that of a 100-year-old man.
The polymath was able to use his skills in art, architecture and engineering to produce images of the body never seen before.
Exhibition curator Martin Clayton, of Royal Collection Trust. said: "This is the first time that Leonardo da Vinci's anatomical drawings have been displayed alongside their modern-day counterparts.
"It's incredibly exciting to discover how Leonardo's investigations 500 years ago foreshadowed the work of today's leading anatomists to an astonishing degree."
Peter Abrahams, professor of clinical anatomy at Warwick Medical School, who helped the show's curators, said: "In many ways Leonardo predicted the 20th-century revolution in various medical imaging techniques.
"His use of cross sections and slices to show deep internal structures within the body foreshadowed the modern techniques of CT and MRI scanning.
"The anatomical accuracy of Leonardo's drawings has rarely ever been surpassed, and I still use them to teach surgeons and medical students today."
The exhibition runs from August 2 to November 10.