Some of the most quoted lines in film history were never typed onto a page by a screenwriter. They showed up on set, sometimes by accident, sometimes because an actor got bored of the scripted version and tried something else. What’s striking is how often these unplanned moments outlast the carefully written dialogue around them, becoming the one thing people remember decades later. The stories behind these lines are almost as good as the lines themselves. Directors who had no idea what was coming, editors who fought to keep a single ad-libbed take, actors who borrowed jokes from the crew. Here are eight of the clearest examples, backed by accounts from the people who were actually there.
1. “You’re gonna need a bigger boat” – Jaws (1975)

Roy Scheider’s line as Chief Brody wasn’t written into Jaws at all. The phrase had started as a bit of a recurring joke among those on set, since the barge used for filming, along with its support boat, was constantly criticized as too small for the job. Screenwriter Carl Gottlieb later confirmed the crew used the line as a catchphrase for anything that went wrong during the troubled shoot.
The phrase became such a common catchphrase around the set that Scheider would start improvising it into various scenes throughout the film. Only one take made the final cut, delivered right after Brody’s first real look at the shark, and it became one of the most quoted lines in cinema. It now ranks 35th on AFI’s list of the top 100 movie quotes.
2. “Here’s Johnny!” – The Shining (1980)

Jack Nicholson’s axe scene is one of horror’s most famous images, and the line that goes with it wasn’t in Stanley Kubrick’s script. Jack Torrance has chopped a hole through the bathroom door to get to his wife Wendy when he says this line, and it is reported that Nicholson improvised it during shooting. He borrowed it straight from American television.
Remember this is 1980, and the biggest name in late night television at the time was Johnny Carson, whose sidekick Ed McMahon always introduced him with “Heeeeeere’s Johnny!” Kubrick, known for demanding dozens of takes on every setup, kept this one exactly as Nicholson delivered it. Given how meticulous the director usually was, that alone says something about how well it worked.
3. “You talkin’ to me?” – Taxi Driver (1976)

Robert De Niro’s mirror monologue as Travis Bickle is often held up as proof of his range, and it turns out most of it came from him rather than the page. The script only said that Travis Bickle should look in the mirror while he was preparing to hunt down criminals, vigilante style. Everything he actually said was invented on the spot.
Paul Schrader, who wrote the film, openly does not take credit for the line, since the original script only read “Travis speaks to himself in the mirror,” with De Niro improvising the dialogue. The result became one of the defining moments of 1970s American cinema, quoted so often that its origin as an unscripted moment tends to get overlooked.
4. “I’m walkin’ here!” – Midnight Cowboy (1969)

This one wasn’t planned as a performance at all. Dustin Hoffman was genuinely reacting to a real taxi that nearly hit him during a street shoot in New York City, and the cameras happened to be rolling.
When a real cab nearly hit Dustin Hoffman during filming, his reaction, slamming the hood and shouting, was genuine, and perfectly fit his character, Ratso Rizzo. Hoffman later described the moment plainly, saying “I wound up saying, ‘I’m walkin’ here!’ But what was going through my head is: ‘Hey, we’re makin’ a movie here!'” It stayed in the final cut and became shorthand for city frustration everywhere.
5. “Here’s looking at you, kid” – Casablanca (1942)

Humphrey Bogart’s toast to Ingrid Bergman is one of the oldest examples on this list, and its backstory is a bit different from the others. Originally scripted as “Here’s good luck to you, kid,” the line was ad-libbed by Bogart, drawing from a casual expression he used off-camera while teaching Bergman how to play poker between takes on the Warner Bros. set.
The change was small, just a few words, but it gave the line a warmth that “good luck” never would have carried. The improvisation enhanced the chemistry between the leads and was retained for multiple scenes, contributing to the film’s authentic emotional depth. It has held up as one of the most recognizable closing lines in American film for more than eighty years.
6. “You can’t handle the truth!” – A Few Good Men (1992)

Aaron Sorkin’s courtroom drama is famous for its rapid-fire dialogue, which makes it a little ironic that its most iconic line wasn’t actually his. The original script called for Nicholson to deliver the line “You already have the truth!” However, in a stroke of spontaneous brilliance, Nicholson decided to change the line on the spot to the now iconic phrase, “You can’t handle the truth!”
Director Rob Reiner has since described just how much Nicholson enjoyed the moment. Reiner remembered his star happily performing the scene over and over again entirely of his own volition. That single swapped phrase is now one of the most parodied lines in modern film.
7. “I know” – Star Wars: The Empire Strikes Back (1980)

Han Solo’s response to Princess Leia’s “I love you” wasn’t in the script either, and it turned into one of the more debated line changes in blockbuster history. This line wasn’t technically improvised on the spot, but it was a change to the script made by Harrison Ford, in a scene where Princess Leia and Han Solo were supposed to confess their love just before Han gets frozen in carbonite.
Ford reportedly felt the scripted “I love you too” didn’t fit the character he’d built over two films. It always bothered people that Han Solo says “I know” in response to Leia telling him she loves him, but it turns out this was because Harrison Ford didn’t think it was in his character to simply say, “I love you too.” The two-word reply ended up saying more about Han than a full declaration ever could.
8. “I am Iron Man” – Iron Man (2008)

Marvel’s entire cinematic universe arguably kicked off with a line that wasn’t planned. Tony Stark’s final press conference was supposed to follow a scripted alibi, but Robert Downey Jr. took a different route. Instead of denying his double life as expected, Downey simply owned it on camera.
Marvel producers kept it, seeing it as the perfect match for Stark’s ego and unpredictability, and the moment reshaped the entire tone of the Marvel Cinematic Universe going forward. Nearly two decades and dozens of films later, that closing line still reads as the moment the whole franchise found its voice. Taken together, these eight moments make a fairly convincing case for leaving room in a shoot for the unexpected. A tight script gets a story to the right place, but sometimes the line people remember for fifty years is the one nobody wrote down at all.
