A show-within-a-show is a fictional television show featured within the fictional universe of a real television show. It often features a frame story.
Historically, the idea of a play within a play is an ancient one, appearing in Ovid's Metamorphoses; William Shakespeare's A Midsummer Night's Dream, etc. Many films also feature this idea, Singin' in the Rain being one example.