Knock-Knock Joke

A common joke, told in the following format: "Person 1: Knock, knock Person 2: Who's there? Person 1: X Person 2: X who? Person 1: Terrible pun based on X."

The format does tend to make it annoying, as the second person usually wants to hear a joke, rather than be forced to participate. But it is possible to make them funny in the right situation. Because this trope is so well-known, it's subverted more often than not, by replacing the punchline with an unexpected insult instead.

A second subversion is when person 1 isn't actually trying to set up a joke, but person 2 acts like it is. Generally this leaves out the 'knock knock' being said, with person 1 knocking on an actual door.

The Other Wiki has an article on this plus examples, even prototypical ones from Shakespeare's time.

Compare Light Bulb Joke, What's a Henway?.

"Paulie: Knock, knock Person 2: Who's there? Paulie: Paulie Shore Person 2: Paulie Shore who? Paulie: Exactly"
 * In Paulie Shore is Dead:

"Dougal: Knock, knock. Ted: Who's there? Dougal: Father Dougal McGuire. Ted: (Wearily) Goodnight, Dougal."
 * In Police Academy 6, Hightower was fighting a thug, and the thug was getting the upper hand enough to tell one of these jokes. It was so bad, it ticked Hightower off enough to punch the guy out.
 * Father Ted:

"Valentine: I'm sorry I don't have any books, puss, but I can tell you a knock-knock joke. I know the best one in the world. Ravenous griffin: The best? Valentine: You start. Griffin: Knock knock. Valentine: Who's there? Griffin: ... [Valentine escapes]"
 * Catch Me If You Can combined a subversion of this with a Precision F-Strike, to good effect.
 * From Mirror Mask:

"Knock-knock. Who's there? Interrupting cow. Interrupting-- MOOOOOOOOO!"
 * There is a book that claimed that this is the greatest knock-knock joke ever:

"Knock-knock. Who's there? Interrupting static coefficient of friction. Interrupting-- Mu!!!"
 * Dominic Deegan introduces a Crowning Moment of Awesome for physics students with a variant:

"Dan: Knock knock. Drey: Who's there? Dan: The interrupting cow. Drey: The interrupting cow who? Dan: [has to think about it] ...Mooooo."
 * Then there's this one.
 * Also turned into a crowning moment of either heartwarming or heartbreaking in the movie Half Nelson.

"Everything's backwards in Australia. They have summer when we have winter, all their teenagers idolize accordion players, and the punchline of all their jokes is "Knock-knock!""
 * And shows up in Ozy and Millie, but with an interrupting space alien.
 * Dave Barry referenced this when writing about the 2000 Olympic Games in Sydney;

"Stewie: "What's that you got there?" Brian: "This is... THE most wrinkled piece of spider web." Stewie: "What happened to the spider?" Brian: "Knock knock." Stewie: "Who's there-- Brian: "I ATE HIM!""
 * From Family Guy. Stewie becomes unbearably nice once he has a near-death experience, so much that he tells Brian a knock-knock joke that ends with "your friend, Stewie, and he'll always be there for you." Brian retaliates:

"Bill: Knock, Knock. Dave: Who's there? Bill: Bill. Dave: Bill who? Bill: That's all I really have so far."
 * In News Radio, Bill tries out his new knock-knock joke on Dave:

"Wakko: "Knock knock." Scratchensniff: "Who's there?" Wakko: "Max." Scratchensniff: "Max who?" Wakko: "Max wants to come in and go crazy!" Scratchensniff: "See, that doesn't make any sense." Wakko: "It does if you knew Max." Scratchensniff: "But I don't know Max." Wakko: "If you did, you'd be laughin'!""
 * In Matt Ruff's Sewer Gas and Electric, in the afterlife, Abbie Hoffman is telling Ayn Rand a Knock-Knock Joke, trying to teach her about humor..
 * This gem from Animaniacs:

"Queen Elizabeth: (knocks on door) Knock knock. Wakko: Who's there? Queen: The Queen. Wakko: The Queen who? Queen: The Queen of England! Wakko: It's not a very funny knock-knock joke ..."
 * And now for a little subverting? First, 'Windsor Hassle':

"Snowball: Here's a little joke for you, Pinky. 'Knock knock.' Pinky: Well, that's not a very funny joke, is it?"
 * Second, with Pinky and The Brain, from 'Welcome to the Jungle':

"The Brain: Who? Snowball: The Brain. The Brain: The Brain who? Snowball: Exactly."
 * Once Snowball finds someone more receptive?

"Haley: "Knock knock!" Crystal: "Who's there?" Haley: "Roland." Crystal: "Roland who?" Haley: "Roland 'Itiative and his four friends Sneak Attack, Sneak Attack, Sneak Attack, and Sneak Attack.""
 * This Order of the Stick.

"Harriet: Knock-knock rook. Dylan: Who's there? Harriet: Orange. Samantha: Banana! Harriet: Orange. Samantha: Banana! It's banana! Banana, banana, banana! Then you say orange. "Orange you glad I didn't say banana?" Four-year-olds are telling this joke!"
 * Studio 60 On the Sunset Strip:

"Deadpool: Knock, knock. Deadpool's Clone: Who's there? Deadpool shoots the clone Deadpool: And voilà!"
 * This dialogue from a Secret Invasion tie-in of "Deadpool''

"Deadpool's Father: Who's there? Deadpool: Wade. Deadpool's Father: Wade... Wade who? Deadpool: (pulling off his mask, revealing his scarred face) Wade until you see what happened to me, dad."
 * Another example with Deadpool. After telling his life story to a movie-maker, Wade knocks on the door of his long-lost father.

"Knock knock. Don't say "knock knock", just knock! What's all this "knock knock" business? I'm just trying to leaven the mundanity of your day. Well, don't try to leaven the mundanity of my day! If I want my mundanity leavened I'll do what I always do. What's that? I will draw a moustache on the TV at random with a marker pen and wait for that glorious yet fleeting moment during the day when Jeremy Paxman becomes General Kitchener."
 * Played with in Bill Bailey's Tinselworm tour:

"Tiffany: Knock knock. Miss Tick: Who's there? Tiffany: Tiffany. Miss Tick: Tiffany who? Tiffany: Tiffany who isn't trying to make a joke. Miss Tick: Ah. That sounds promising. Come in."
 * Subverted in the Discworld novel The Wee Free Men when Tiffany first visits Miss Tick, who is currently working out of a tent that has no actual door:

"Person 1: Knock knock! Person 2: Who's there? Person 1: Amy Fisher. Person 2: Amy Fis- Person 1: BANG!"
 * Depending on your tastes, the following is either a case of Dude, Not Funny or Gallows Humor:

"Knock-knock! Who's there? Heh heh! Nobody's here."
 * Ernie Steele of Backyard Sports does not use puns in his Knock Knock Jokes, but instead stops them in the middle. For example:

"WILLOW: I got her head back on, didn't I? And I got her off those knock-knock jokes. BUFFYBOT: Ooh, who's there? XANDER: You know, if we want her to be exactly- SPIKE: She'll never be exactly. XANDER: I know. TARA: The only really real Buffy is really Buffy. GILES: And she's gone. BUFFYBOT: "If we want her to be exactly she'll never be exactly I know the only really real Buffy is really Buffy and she's gone" who?"
 * The children's book Camp Knock-Knock is about a kid having a knock-knock joke challenge involving names, and getting stuck with the name Frederick Ornat.
 * Prarie Home Companion did a whole song based on knock knock jokes which is surprisingly catchy, and can be heard here with the jokes starting at 0:40.
 * The Buffybot tries for an epic one:

"Wayne: They're so accurate they can just fly in through the door. It's like, "Knock Knock!" Garth: "Who's There?" Wayne: "Ka!" Garth: "Ka who?" Both: "KA-BOOM!""
 * Saturday Night Live, a 1991 Wayne's World sketch from the first Gulf War. Wayne and Garth are geeking out over the new US smart-bombs and the novel first-person Night Vision footage on CNN.

"Dale: Knock knock. Bill: Who's there? Dale: Boo Bill: Boo who? Dale: Boohoo Hank."
 * During one of Mitch Hedberg's stand-up routines, where he talks about hotels, he says he likes to wear signs around his neck "so little kids can't tell [him] knock-knock jokes. 'Hey, how you doing, nephew?' 'Knock-knock...' 'Read the sign, punk!'"
 * A King of the Hill episode when the gang are at the alley after Hank cried in a romance film.

"Morte: Hey, Nordom... Knock-Knock. Nordom: Why do you persist in addressing me as a door? Morte: It's a joke, you stupid polygon. You're supposed to answer 'who's there?' Nordom: I know who is there. It is you. Why would I ask a question when I know the answer? Morte: You know what, just forget it."
 * In Planescape: Torment, with Morte trying to get Nordom to play the Straight Man:

"Knock knock. Who's there? Anna Maria Alberghetti. Anna Maria Alberghetti who? ..."
 * The first movement of PDQ Bach's cantata "Knock, Knock," and its alternate version, "Sam and Janet."
 * An episode of The Mary Tyler Moore Show had Ted Baxter write his own knock-knock joke, but getting stuck on the punchline:

"Anna Maria Alberghetti in a taxi, honey, better be ready 'bout half past eight...."
 * He eventually comes up with one at the end of the episode that Mary thought was Actually Pretty Funny:

"Knock knock. Who's there? Cancer! Oh, good, come on in, I thought it was Britta."
 * In the Community episode "The Science of Illusion" Britta delivers this Knock-Knock Joke in a Crowning Moment of Heartwarming after being called a Buzz Kill several times in the episode:

"Person 1: Knock knock. Person 2: Who's there? Person 1: Riverboat. Person 2: Riverboat who? Person 1: Riverboat young when I first saw you..."
 * In the Philippines, a popular variation is to replace a line in a song with a knock-knock joke. Popularized in a noontime show named Eat Bulaga! An example:

"Person 1: Knock knock. Person 2: Who's there? Person 1: You know... Person 2: You know who? Person 1: AAAAAAAAAAAHHH!!!!!!!"
 * A really bad Harry Potter related one:

"N. Bison: Knock knock! Dr. Insano: Who's there? N. Bison: GUN!!! {points a gun at Dr. Insano}"
 * A subversion from Kickassia, when N. Bison has Dr. Insano cornered:

"Michael: Knock Knock Pam: Who's there? Michael: Buddha Pam: Buddha who? Michael: Buddha this bread for me (produces bread and butter)"
 * Played with on The Office episode "Golden Ticket"

"Dwight: Knock knock! Michael: Who's there? Dwight: KGB Michael: KGB who? Dwight: (interrupts Michael by slapping him) We will ask the questions!"
 * Later

"Beavis: Knock knock. Butthead: Who's there? Beavis: Ura. Butthead: Ura who? Beavis: You're a buttmunch, dillhole, dumbass, and a turd!"
 * From Beavis and Butthead:

"Butthead: Knock knock. Beavis: Who's there? Butthead: Ura. Beavis: Ura who? Butthead: Ura-ine. Urine."
 * Later

""I like to float that one early to see how literate I can get with the audience...so I think I'll try some knock-knock jokes! Knock-knock!" "Who's there?" "Nobody, I just like to wield that level of power over the audience. I say 'knock-knock', thousands of people say 'Who's there?'. It's the closest I'll ever come to Jonestown.""
 * No actual examples, but in Angels of Light and Darkness, Suzie tells a stupid joke that isn't one, and John comments that her sense of humor is declining to the point where she'll be invoking this trope, next.
 * Dennis Miller in his 1993 HBO special, after a joke bombs early on:

""Who's there?" "Sam and Janet." "Sam and Janet who?" (sings)"Sam and Janet evening...""
 * One time in The Wonder Years, after an awkward silence between her and Kevin following a serious spat, Winnie signals her willingness to reconcile with a knock-knock joke:

"Give me a Knock Knock Joke Don't knock a Knock Knock Joke They're always dumb So tell me how come After one I laugh and bubble up After four I always double up? Don't be an old slowpoke Give me a Knock Knock Joke Please! That was a Knock Knock Joke I love a Knock Knock Joke! They can be awful, it's true Still I'm telling you I love a Knock Knock Joke Yeah!"
 * Regularly featured as a segment on Lamb Chop's Play-Along, and honored with a song to boot.
 * knock knock jokes ensue*

"Brendon: (Shouting angrily) YOU KNOW WHAT!? KNOCK KNOCK! Linda: WHO'S THERE!? Brendon:"
 * An absolute classic from an episode of Home Movies, while Linda is giving birth.

"Zorak: Alright, here we go. Er, uh, um... Knock knock? Space Ghost: Um, who's there? Zorak: (beat) F*ck you."
 * Possibly stolen from Space Ghost Coast to Coast:

"Knock knock. Who's this? Yorg. Yorg who? Yorg Onnaregretitifyouopenthiscoffin!"
 * In Quest for Glory IV, this is your cue that you should NOT open a coffin, unless you have a ton of HP.

"Tim: Knock knock. John: Who's there? Tim: Oh, you've heard it..."
 * One episode of Hello Cheeky subverted this delightfully.