Once Upon a Mattress is a musical comedy with music by Mary Rodgers, lyrics by Marshall Barer, and book by Jay Thompson, Dean Fuller, and Marshall Barer. It opened off-Broadway in May 1959, and then moved to Broadway. The play was written as an adaptation of the Hans Christian Andersen fairy tale The Princess and the Pea.