A novelisation of the "lost" Doctor Who adventure Shada, scripted by Hitchhiker's Guide author Douglas Adams in 1979, will be published next year.

Adams wrote three series of Doctor Who in the late 1970s, when he was in his twenties and The Hitchhiker's Guide to the Galaxy was first airing as a BBC radio comedy. Shada was intended as a six-part drama to finish off the 17th season, with Tom Baker in the role of the Doctor.

In the story, the Time Lord comes to Earth with assistant Romana (Lalla Ward) to visit Professor Chronotis, who has absconded from Gallifrey, the Doctor's home planet, and now lives quietly at St Cedd's, a fictional Cambridge college. (The Doctor: "When I was on the river I heard the strange babble of inhuman voices, didn't you, Romana?" Professor Chronotis: "Oh, probably undergraduates talking to each other, I expect.")

Chronotis has brought with him the most powerful book in the universe, The Worshipful and Ancient Law of Gallifrey - which, in a typical touch of Adams bathos, turns out to have been borrowed from his study by a student. Evil scientist Skagra, an escapee from prison planet Shada, is on its trail.

Large parts of the story had already been filmed on location in Cambridge before industrial action at the BBC brought production to a halt. The drama was never finished, and in the summer of 1980 Shada was abandoned – although various later projects attempted to resurrect it.

Douglas Adams's Doctor Who series are among the very few which have never been novelised, reportedly because the author wanted to do them himself but was always too busy. Gareth Roberts, a prolific Doctor Who scriptwriter, has now been given the job.

Publisher BBC Books declared the book "a holy grail" for fans of the series. Editorial director Albert De Petrillo said: "Douglas Adams's serials for Doctor Who are considered by many to be some of the best the show has ever produced. Shada is a funny, scary, surprising and utterly terrific story, and we're thrilled to be publishing the first fully realised version of this Doctor Who adventure as Douglas originally conceived it."

Ed Victor, the literary agent representing the Douglas Adams estate, said: "The BBC have been asking us for years [to allow a novelisation of Shada] and the estate finally said: 'Why not?'" Having Roberts novelise the Adams script was "like having a sketch on a canvas by Rubens, and now the studio of Rubens is completing it," he added. The book will be published in March 2012 as a £16.99 hardback.

Adams died in 2001, and a posthumous collection of his work, including the unfinished novel The Salmon of Doubt, was published the following year. A Hitchhiker's Guide followup, And Another Thing..., written by Eoin Colfer, was published in 2010, but Victor said there were "no plans at the moment" for more such sequels.