A grimoire is a textbook of magick, like a primer. Although the term grimoire is used by some Pagans interchangeably with Book of Shadows, the flavor of this term is somewhat more specific, and not exactly Pagan, due to its historical roots.
Grimoires became very popular from the 1600's to the 1800's. These texts were often used by ceremonial magicians to conjure and control demons, angels, spirits, etc.
Grimoires contain elaborate rituals, many of which are echoed in modern Witchcraft rites such as consecrations and quarter calls. The Key of Solomon is a famous grimoire that contains the most correlations with Witchcraft rites. Doreen Valiente and the Farrars (Janet & Stewart) suggest that the material was adopted by Gerald Gardner to fill the missing gaps in some rituals. It has also been suggested that Aleister Crowley aided or encouraged these adaptations.
To read more about grimoires, see the PaganPath Library article in the Cauldron area <a href='http://paganpath.com/library-2/the-cauldron/43-grimoire'>here</a>.