The most important literary device in the novel is the use of a fictional encyclopedia, which explains some of the important events and themes. The Hitchhiker's Guide, in the book, is a real traveler's guide, containing often-inaccurate but usually insightful information about everything in the galaxy. This is intended to replace a larger resource, and provide fast advice for dealing with unexpected situations. This acts as a plot point; Ford Prefect is a writer for the Guide's publisher and was stranded on Earth while gathering information for the updated edition.
(Excerpt from The Hitchhiker’s Guide to the Galaxy, Page 634784, Section 5a, Entry: Magrathea)
Far back in the mists of ancient time, in the great and glorious days of the former Galactic Empire, life was wild, rich and largely tax free. Mighty starships plied their way between exotic suns...
(Adams, The Hitchhiker's Guide to the Galaxy, Google Books)
This is an example of epistolary literature, in which fictional documents are used to inform or bolster the story. Guide entries show an extremely diverse population of creatures and events, allowing Adams to hint at an enormous, populated universe, the scope of which is far beyond human ability to change or even comprehend.