Usually written by the author of the book, a preface may state the purpose of the book and what areas it does and doesn't cover, to give the reader a sense of the book's scope. A preface of a fictional novel may present reasons for writing the book, or how the book's conception arose.
Sometimes prefaces provide historical background for their books. Thomas Hardy, a 19th century novelist who frequently prefaced his novels, sometimes explains if the characters or settings in his books are based on any real persons or places.
Thomas Hardy also notes in his prefaces when an editor or publisher has made a change to the original manuscript. Subsequent editions of a book, after the first has achieved great success, may include a preface where the author comments on his unprecedented accomplishment.
When authors write about a controversial subject, they sometimes include a preface that apologizes or sometimes defends their writing, especially in the case of subsequent editions. Thomas Hardy's "Jude the Obscure" and Nathaniel Hawthorne's "The Scarlet Letter," both novels that narrated scandalous stories for their respective time periods, added prefaces to later editions defending their writing.
A preface may briefly list individuals the author wishes to thank for inspiration, editing or proofreading or publication.
Critics have sometimes viewed prefaces as a kind of advertisement for a book. Mark Twain wrote a humorous preface for "Huckleberry Finn," the playfulness of which may have encouraged many readers to pick up the book:
NOTICE
Persons attempting to find a motive in this narrative will be prosecuted; persons attempting to find a moral in it will be banished; persons attempting to find a plot in it will be shot.
BY ORDER OF THE AUTHOR