For the Funnyz

This is a situation where a character is so overcome with the desire to make a funny joke (funny to them at least), that they will make it, regardless of whether it's even remotely appropriate for the current circumstances. While antics motivated this way are often quite funny to the audience, other characters will regard this behavior as a source of serious frustration and on obstacle needing to be overcome.

This is such an ingrained part of a character's personality that even if they try to repress it, the joke will only become more inappropriate or offensive when he inevitably cuts loose. It can then turn into become a Cold Turkeys Are Everywhere moment for the character as straight-lines pop up all over the place.

Operates on the same basic principle as For the Evulz and It Amused Me. This is the in-universe invocation of Rule of Funny.

Film

 * Star Trek Generations. Upon activating his emotion chip, Data is forced into enacting this trope, uncontrollably making bad jokes about everything. This seriously annoys Geordi, until he realizes Data's compulsive joking is being caused by the emotion chip malfunctioning.
 * In Who Framed Roger Rabbit? toons in general (and Roger in particular) appear to be compelled by biology into making jokes. Roger, as an example, can't resist completing "Shave and a Haircut," even when he's hiding from the very person who is setting him up. Although on the bright side, he can also escape from handcuffs...if it's the punchline to a joke.
 * Dr. Alan Grant in Jurassic Park, not exactly the funniest or nicest guy in the movie, nevertheless gets one in on the kids when he grabs the (inactive)perimeter fence and screams like he's being electrocuted. Alexis was not amused, but Tim thought it was funny.

Western Animation

 * Freakazoid had this as his biggest weakness. When fighting That Guy, Freakazoid insists on saying his name even as the captives beg him not to. When asked why he said the name, knowing what would happen, Freakazoid explains that he was attempting to invoke a Gilligan Cut.
 * One episode of South Park had Kyle paying Cartman not to make jokes at the expense of his sterotypically-jewish (Woody Allen Up to Eleven) visiting relative. Less then five minutes pass and Cartman makes a pun about the Holocaust.
 * The Simpsons had Bart caught up in this trope when performing for the Olympic committee. Bart's stand-up comedy act consists almost entirely of him making jokes directly insulting the committee member's nationalities. When Chalmers demands to know what could have possibly made Skinner think putting this act on was a good idea, all a chuckling Skinners can say is "it was good in rehearsal". He quickly catches on, though, when Bart asks Chalmers where he grew up and Chalmers responds with a string of ludicrously obvious set-ups to punch lines.

Anime & Manga

 * In one episode of Azumanga Daioh, while visiting Chiyo's summer home, right when they're about to enter the house, Chiyo announces apropos of nothing that they won't be able to get in the house if she loses the keys. Tomo promptly grabs the keys of out Chiyo's hands and tosses them into some tall grass, proclaiming it a hilarious joke. When they later locate the keys, Tomo is restrained to keep her from doing it again.
 * In a later episode, Chiyo is as excited as can be about the upcoming class trip to Okinawa, and is equally crushed when Yukari announces it's been canceled. Yukari almost immediately admits she was joking, and just wanted to mess with Chiyo's head.
 * In an early Keroro Gunsou episode, Keroro tries to warn the Hinatas about the traps Giroro has set, but can't resist stepping on a Banana Peel thrown by Giroro.
 * In Nichijou, a lot of the antics of the eight year old Professor fall into this. Examples include constantly modifying her robot Nano with things like hidden dessert compartments and over the top reactions.

Literature

 * Harry Dresden in The Dresden Files has a near-pathological need to wisecrack about things, provided his Berserk Button has yet to be pushed. He will snark at villains and heroes and would-be allies alike, and one of his defining character traits according to the RPG is "Epic Wiseass" (which, by the rules, means the GM can reward his player if he ends making trouble for himself by up cracking jokes at and pissing off someone he really shouldn't have). It should be noted that when Harry gets sufficiently riled or frightened, he stops, and it's usually an indicator that things are really serious.

Live Action Television

 * No matter the consequences, no matter the situation, Michael Scott will say "That's what she said!" He once said it within minutes of being reprimanded for saying it.
 * Scott's predecessor in the British version of The Office, David Brent, had a similar problem; his jokes were less predictable, but equally unfunny. These two may be the patron saints of this trope.
 * In the Doctor Who episode "Tooth and Claw", Rose attempts to get Queen Victoria to say, "We are not amused", with increasing desperation.
 * Eventually Victoria snaps at her and demands to know why she's being such a twit (not exact words, but the same feeling).
 * Most Doctors and even their companions get this as one of their character traits. They just can't help it with the snarking. On the whole, its probably because being terrified for your life thing gets old after the fifth adventure, but partly due to Obfuscating Stupidity on the Doctor's part.
 * Buffy the Vampire Slayer's Xander has a tendency to do this.
 * Chandler on Friends to the point that his friends made him make a New Years Resolution to stop.

Music

 * One Week by the Barenaked Ladies: "I'm the kind of guy who laughs at a funeral / Can't understand what I mean? You soon will".

Web Original

 * The Annoying Orange. See some here.