A character sees or hears that someone is coming. Thinking that it's a bad guy, he prepares a mallet, a baseball bat, a net, etc. When the person appears, he strikes...and then notices that it was his friend rather than a bad guy.
Usually, while the character is distracted tending to his injured friend, the real bad guy will come up behind him.
Compare Friend or Foe. Sister trope of Cat Scare where approaching danger turns out to be a harmless critter. See also Don't Sneak Up On Me Like That and Trapped the Wrong Target. If a villain sets someone up to do this, see Disguised Hostage Gambit. Not to be confused with Self-Harm or Offending the Creator's Own.
- In Fruits Basket, Tohru is walking home from work when she hears someone is following her. Remembering there were rumors of a pervert hanging around she bashes the person in the head with her school bag. Turns out it was just Kyo who came to meet her.
- In Jonah Hex, Jonah was leading the Confederate soldiers who opened fire on Stonewall Jackson (see Real Life examples below).
- Themaze Agency: In "Two Wrong Rhodes", Jen and Ashley both have the idea of breaking into the Victim of the Week's apartment to search for evidence. In the darkened apartment, each thinks the other is the killer, and they wind up grappling on the floor. Much to Gabe's delight when he turns on the lights.
- In a crossover between Spider-Man and Wolverine, a friend of Wolverine's uses this to get Spider-Man to kill her: he's just fought off Wolverine and, when his Spider-Sense goes off, Spidey thinks he's back for round two and strikes...
- In Robyn Hood: I Love NY #3, Robyn is blinded and deafened by a flashbang and winds up attacking Agent Red because she can't see who it is or hear Red desperately shouting out her identity.
- Spider-Man: Into the Spider-Verse: When Peter B. Parker first shows up, his shadow matches Prowler's, and it even starts to play Prowler's music. Miles Morales hits him with a venom strike before realizing he's not a threat.
- Non-humorous example: In The Departed, Colin Sullivan stabs some random restaurant worker in the chest that he mistakes for Billy Costigan.
- Used in Friday the 13th Part VIII: Jason Takes Manhattan. In retrospect, maybe it was a bad idea to give the gun to the guy who needs glasses to see properly before splitting up. Actually, wait...
- In the Get Smart movie, Max sees a silhouette of what he thinks is a KAOS agent, so he takes a fire extinguisher and hits the silhouette in the head. He then finds that he knocked out the Chief of CONTROL.
- In Indiana Jones and the Last Crusade, Henry Jones Sr. beans his son with a vase when Indiana jumps in through the window of the castle the Nazis are holding him in.
Henry Jones Sr.: I thought you were one of them!
Indiana Jones: They come through the door!
Henry Jones Sr.: Good point!
- In the first Scary Movie, a young woman beats a group of trick-or-treaters senseless in this context.
- Used to gruesome effect in the horror movie The Strangers: the two main characters, terrorized in their home by masked invaders, are hiding behind a makeshift barricade in a back room with a shotgun, waiting in terror for their pursuer to appear in the doorway... and when someone finally does, the male protagonist shoots immediately, blowing the head off of— his best friend Mike who has come to pick them up.
- Another Non-humorous example pretty much sets up the entire plot of Blade: Trinity. Although in that case it was a bad guy, deliberately tricking Blade into making the mistake.
- Every possible variation of this trope was more or less invented by The Three Stooges.
- In a likely homage, Sam Raimi used this gag in both Evil Dead 2 and the prototype short film Within the Woods.
- Also used with Laurel and Hardy when they tried to Shanghai sailors. Oops.
- Nonviolent example in The Name of the Rose, Adso gets separated from William while in the catacombs, and they try to find one another by voice. Adso suddenly sees a figure with a lamp across the hall, and calls out that he sees someone. It's William, and he identifies himself by flickering his lamp three times.
- Columbus does this to Bill Murray in Zombieland. He had it coming, though.
- In Johnny English, Johnny performs this, then pins it all on a mysterious "aggressor". He then goes on to stage a fight between himself and himself... the "aggressor" in the next room.
- At the climax of The Catcher, Johnny and Walker and struggling with each other on the diamond, dressed in identical catcher's outfits. Terry grabs a splintered bat and stabs who she thinks is Johnny in the back, only to realise her mistake when Johnny grabs her from behind.
- In The Man Who Killed Don Quixote, Toby accidentally clobbers Javier with the stone arm of a statue when Javier is running to his rescue in Jacqui's bedroom at Alexei's castle.
- In Death Bell, a spooked Miss Choi swings at an opening door when she is searching the deserted school. It is the security guard and she buries the nails in the plank she is wielding into his palm.
- Burn After Reading: Harry's uncompromising reflexes cause him to instinctively shoot Chad dead when he mistakes him for a robber. It happens so fast that it takes a moment for Harry to even realize what he just did; he even runs out of the room in his panic, only to stop and realize that his "attacker" isn't chasing him.
- Slaughter High: Thinking she is the last survivor, Carol hears someone approaching on the other side of the curtain and assumes it is Marty coming to finish her off. She blindly swings a hatchet at the figure only to discover she has buried the axe in Skip's skull.
- In Varsity Blood, the badly wounded Bubba staggers out of the house and comes up behind Final Girl Hannah. Hearing someone behind her, and thinking it is the killer, Hannah spins around and stabs Bubba in the chest.
- Long Weekend: After Marcia drives off, Peter is forced to spend the night outdoors on the beach. Firing at all of the strange noises he hears in the darkness. Running out of bullets, he loads the speargun and sits clutching that. Hearing another noise, he fires the spear and noises cuts off. Come the morning light, he finds he has shot and killed Marcia who had crashed and was making her way back to the camp.
- Ask a Policeman: When cornered by the smugglers in the police station, Sgt. Dudfoot overturns the desk, smashing the lantern to the floor and plunging the room into darkness. Sounds off a massive struggle follow. When the lights come back on, Dudfoot, Brown and Harbottle are tangled up in a heap, and they have managed to handcuff themselves together.
- In Evil Breed: The Legend of Samhain, Shae hears someone coming around the corner in the mine tunnel and, assuming it is one of the cannibals, stabs them with a machete, only for it to turn out to be Paul.
- Hot Spur: When Jason arrives to free her, Susan mistakes him for Carlo and stabs him to death in a blind fury.
- Tragic example in the short story "Someone in the Room" by Elizabeth Fancett. A mother kills her own small son thinking he's a prowler.
- Non-humorous example: When Faith in Buffy the Vampire Slayer staked the mayor's aide, believing him to be a vampire.
- In Heroes, Maya, somehow managing to keep hold of a baseball bat and an Idiot Ball at the same time, does this to Mohinder once. Because a superpowered Serial Killer a) would totally jangle the lock on the front door in broad daylight, and b) would be far more damaged by a baseball bat than by Maya's own superpowers.
- In an episode of Hogan's Heroes, after a lady prisoner nearly brains Hogan with her high heel:
Hogan: Watch it! I'm an American — and a veteran.
Prisoner: I thought you were one of the guards!
Hogan: Germans come through the door; Americans come through the floor.
- In the Blake's 7 episode "Redemption", Vila opens the lock on Avon's cell, steps through and is punched in the stomach. On the plus side, Avon actually apologised to him.
- Doctor Who: In "The Romans", Barbara hits Ian over the head with an urn while trying to attack the intruders in the villa.
- Leverage: In "The Beantown Bailout Job", Sophie drives off an attacker who was trying to kill Nate, and Nate chases the attacker out of the apartment. When she hears someone coming back, Sophie slams them in the face with a tray, only for it to turn out to be Nate.
- Agents of S.H.I.E.L.D.: Played for Laughs in "S.O.S." Skye manages to convince Lincoln to make a HeelFace Turn. Seconds later, Mack enters the room and, not knowing this, immediately clubs Lincoln on the back of the head and knocks him out.
- The New Avengers: In "To Catch a Rat", Purdey and Cromwell end up attacking each other when they both have the same idea of searching Cledge's apartment in the dark.
- The Coroner: In "Those in Peril'', Jane attempts to save Mick when he is being strangled by attacking the assailant with stun gun she confiscated off Mick earlier. She ends up hitting Mick with the stun gun while the attacker flees.
- One episode of Law & Order had Ed Green approaching a witness they wanted to question only to get punched in the stomach when she mistook him for a mugger. (He and Lennie then leverage the incident to get the information they need.
- In the first Midnight Caller episode, Jack Kilian sees a man pulling a gun on him and shoots him to death. He realizes too late that the man he shot was his partner, who was pulling his gun out to save Jack because the suspect was right behind him.
- On the Mexican sitcom, El Chapulín Colorado, whenever the titular hero is invoked, he'll be told by the person who called him that another person is causing problems, Chapulin will say he's detecting an enemy with his vinyl antennae, Chapulin would knock out the other person, and proudly proclaim he's subdued the villain. The person who called hikmin would then inform him he knocked out an ally. Other episodes has him ignoring, or even aiding the actual villain while continually attacking an ally until very late on he'll be told of his mistake.
- In the Starsky & Hutch episode "The Las Vegas Strangler," the guys are fighting Starsky's Girl of the Week's vengeful ex-husband in a swimming pool. At one point Hutch gets confused, shoves Starsky away from the man, hauls him out of the water, and almost punches him before he realizes his mistake.
- In the Here Come the Brides episode "The Crimpers," Joshua and Jeremy get into a fight in the dark with Jason and Stempel, with each pair thinking the others are kidnappers.
- Semi-common spot in Professional Wrestling, between friends, allies, and tag teams; a series of these can herald a breakup, either because the attacker does it so often it's really not an accident..or the attacker really is just that incompetent and means well but the victim snaps.
- When pigs launch Hostile Show Takeover of The Muppet Show, Kermit and Fozzie are locked into the boiler. Fozzie decides to club the pig guard to escape, but when the door opens its actually Gonzo, the latest hostage who gets conked!
Fozzie: Oh Gonzo, I'm sorry. I thought you were a pig.
Gonzo: Terrific, terrific. First he clobbers me then he insults me!
- Non-humorous example: The death of Polonius in Hamlet. Hamlet thought it was pretty funny, though. And many who had Polonius's advice quoted at them as wisdom for years would agree.
- Happens in Assassin's Creed II when Ezio returns home after his father and brothers are hauled off by the Florentine guard. The maid assumes he's another guard coming for his mother and sister and takes a swing at him with a candlestick holder as he comes through the door. A Quicktime Event determines if he gets clocked or not, and the scene continues regardless.
- Batman: Arkham Series:
- Batman: Arkham City: This can happen to Batman in Arkham City while in the Joker's warehouse. One of the medics is hiding from thugs and when she hears Batman approach she jumps out from behind some boxes and takes a swing at his head with a 2x4. Being Batman, you can stand there and take it with no ill effects whatsoever.
- Repeated in the prequel, Batman: Arkham Origins, this time with a corrupt Warden.
- In The Walking Dead DLC 400 Days, Bonnie kills Dee by accident when cornered in the cornfield, mistaking her for one of the group chasing them that had come after her. She doesn't realize who she has struck until it's too late.
- A Running Gag in Xenogears involves Bart repeatedly mistaking Fei for an enemy, to the point where he shoots down a massive airship that Fei and the rest of the Kislev party are currently hijacking, without checking to see if it was friendly first.
- Parodied in the Family Guy episode "The Griffin Family History". When the house is broken into, Peter arms himself with a baseball bat and goes to investigate. He comes across Meg in the hall and stares at her while she asks several questions about what is going on. He then whacks her and says, unconvincingly "Sorry, Meg, you startled me." She was not amused.
- Fat Albert and the Cosby Kids: In "Lying", the gang leap into a muddy river to practice alligator wrestling only to wind up wrestling each other because no one can see anything in the muddy water.
- Gasp!: In "Beware of the Carp", Gasp employs an increasingly wacky security system to keep out a bandit, not realising it's just Dad trying to get back in.
- In one episode, Daphne mistakenly clobbered Shaggy with a vase in this context.
- Narrowly averted in original series episode "Haunted House Hang-Up" (with the Headless Specter), when Fred is holding up a vase to conk the bad guy with. Luckily, Shaggy yells "Hold it!" in time for Fred to recognize him and hold off.
- Used in Teen Titans once. Fortunately, they recognize each other before they attack.
- In an episode of Thunder Cats, Mumm-Ra tricks Lion-O into attacking Tygra with the Sword of Omens this way. Because the Sword can only be used for good, it breaks, forcing Lion-O to risk his neck finding someone who can repair it.
- Example, with guns: The death of Thomas "Stonewall" Jackson.
- Jackson and his group were probing Federal lines very late at night some days into the Battle of Chancellorsville. As they returned, a Confederate picket line encountered them and opened fire. They tried to call out that they were firing on their own men, but the picket officers claimed it was a Yankee lie.
- Mickey Marcus. The guy whom Kirk Douglas portrayed in "Cast a Giant Shadow". The exact circumstances of his death were slightly different (and just a bit more understandable) than those in the movie.
- In one of the non-fiction books by Michael Veitch in which he interviews Australian WW2 flyers, he interviewed a turret gunner who barely avoided shooting a menacing plane that loomed out of the dark, only for it to turn out to be another Lancaster bomber. When he reported this to his commander however, the latter was furious that he hadn't fired the moment he saw a threat, regardless of who it turned out to be.
- The military has various names for situations like this; "friendly fire" and "blue on blue" are some of the most common.