A frame story (also frame tale, frame narrative, etc) is a narrative technique whereby a main story is composed, at least in part, for the purpose of organizing a set of shorter stories, each of which is a story within a story.
This literary device often acts as a convenient conceit for the organization of a set of smaller narratives which are either of the devising of the author, or taken from a previous stock of popular tales slightly altered by the author for the purpose of the longer narrative. Sometimes a story within the main narrative can be used to sum up or encapsulate some aspect of the framing story, in which case it is referred to in literary criticism by the French term mise en abyme.
An early example of the frame story is The Book of One Thousand and One Nights, in which the character Shahrazad narrates a set of fairy tales to the King Shahriyar over many nights. Many of Shahrazad's tales are also frame stories, such as Tale of Sindbad the Seaman and Sindbad the Landsman is a collection of adventures related by Sindbad the Seaman to Sindbad the Landsman.
An extensive use of this device is Ovid's Metamorphoses where the stories nest several deep, to allow the inclusion of many different tales in one work.
Frame stories are often organized as a gathering of people in one place for the exchange of stories. Each character tells his or her tale, and the frame tale progresses in that manner. Famous frame stories in this mode are Geoffrey Chaucer's Canterbury Tales, about a group of pilgrims who tell stories on their journey to Canterbury, and Boccaccio's Decameron.
Sometimes only one storyteller exists, and in this case there might be different levels of distance between the reader and author. In this mode, the frame tale can sometimes become more fuzzy. In the case of Washington Irving's Sketch Book which contains "The Legend of Sleepy Hollow" and "Rip Van Winkle" among others, the conceit is that the author of the book is not Irving, but a certain gentleman named Crayon. Here the frame includes both the world of the imagined Crayon, his stories and the possible reader who is assumed to play along and "know" who Crayon is.
As with all literary conceits, the frame tale has many variations, some clearly within the confines of the conceit, some on the border, and some pushing the boundaries of understanding. The main goal of a frame tale is as a conceit which can adequately collect otherwise disparate tales. It has been mostly replaced, in modern literature, by the short story collection or anthology absent any authorial conceit.
To be a frame narrative, the story must act primarily as an occasion for the telling of other stories. If the framing narrative has primary or equal interest, then it is not usually a frame narrative. For example, Odysseus narrates most of the Odyssey to Nausicaa, but, even though this recollection forms a great part of the poem, the events after and before the interpolated recollection are of greater interest than the memory.