The film is based on a true story. Set in the year 1997, David Scott Ghantt (Zach Galifianakis) thought being an armored car driver would be a dream come true. He discovers that it's pretty boring stuff, and he often fantasizes about getting robbed. Everything changes when he meets Kelly Campbell (Kristen Wiig), a new employee at his bank, Loomis Fargo. David and Kelly hit it off at a shooting range where David accidentally shoots between his buttcheeks. He is in love with Kelly, but he is already engaged to Jandice (Kate McKinnon), a strange woman originally engaged to David's distant cousin before his death.
David goes to an awkward engagement photo shoot. One day at work, David and Kelly's boss yells at the two of them to go back to work, so Kelly stands up for David. She argues that even if she gets fired, she can collect unemployment. She pushes it too far when she pretends to sexually harass David and grab his belt, causing his gun to go off and shoot a window.
Now she's definitely fired. Before Kelly leaves, David asks for her number. She adds the numbers 143 to the end since it means "I love you" to her, and it's sort of like a signature. Kelly stays with her childhood friend Steve Chambers (Owen Wilson), his wife Michelle (Mary Elizabeth Ellis), their sons and two friends of Steve. After watching a news report on Phillip Johnson robbing from another Loomis Fargo bank, Steve concocts an idea to rob Loomis Fargo so they can escape their dead end lives and get away with some money. He persuades Kelly into getting in on the plan by getting David in on it since they know he likes Kelly.
Kelly gets in contact with David to bring him onto the plan, with Steve hiding his face from David but also giving him instructions. Since he would rather follow her than get married to Jandice, David agrees to help. She then guides him through some "training", which includes eating a tarantula since he may be living off the land after the plan goes off. The team has David go inside the bank's vault and load as many bills as he can into the back of a truck.
He nearly gets caught by another guard, but that man just assumes that David got overtime. Two hours later, David is done, and he breaks three cameras and steals two security tapes, but he misses one tape and another camera. He tries to close the backdoor but ends up locking himself in the back. He tapes some stacks of money together to drive the van through a door and into a ditch as the others watch.
They are then amazed by how much money David has nabbed. The money is counted and comes out to $17 million. David flees to Mexico to wait for Steve to send him money and to also lay low, with a bunch of money stuffed in his underpants already. However, Special Agent Scanlon (Leslie Jones) and her partner (Jon Daly) are already on the case, and Scanlon is pissed since the money stolen was federal agent money. They bring the security tape to Jandice and show her that David is guilty. After indulging in their share of the wealth, Steve thinks it's time to cut David loose since the FBI are after him, but Kelly thinks it would be wrong to screw David over now.
Three Interpol agents arrive at the hotel where David is staying to look for him. They miss him as he tries to refill his ice bucket, but the concierge rats him out. David flees and manages to escape. He dons a disguise to evade capture and then calls Kelly to tell her what happened. He looks through his pocket and finds a wallet with Steve's name and face on it.
When he drops Steve's name, Kelly and Steve become worried. Steve hires dim-witted hitman Mike McKinney (Jason Sudeikis) to kill David. He goes down to Mexico to buy a gun, but he buys a wooden display gun that even the seller says isn't worth anything. When Mike attempts to kill David in the streets, the gun backfires and blows up in his face. He then goes after David after instigating a chase (he likes it that way), which results in multiple car accidents.
Scanlon goes around asking about David and how he can be found. Everyone tells her to go to Kelly. Scanlon and her partner talk to Kelly, who quietly breaks down when she realizes David is in trouble. Mike eventually gets David by knocking him unconscious.
He gets ready to cut David up until he looks at his ID and sees that Steve used Mike's own name and information to give David a fake ID. Thinking David was born under the same circumstances as him, Mike gives up trying to kill David because he thinks they were brought together by fate, so they become buddies. David calls Steve and demands that he send him money within two days, or else he will turn himself into the authorities and name-drop Steve first. Kelly is at a clothing store when she is confronted by Jandice near the fitting rooms. She knows that Kelly was David's "mistress", and she attacks her. The two fight in front of everyone, with Kelly getting Jandice off by hitting her with a mannequin body. One of Steve's guys then follows Kelly. David calls back when he finds that Steve did not transfer money to his account.
Steve then reveals that he has Kelly as a hostage, and he orders David to go to South America until he receives further instructions, or they will hurt Kelly. David is getting ready to leave from the airport, just as the same three Interpol agents are there looking for him. Mike is there too, because he is heading back to the States to kill Kelly under Steve's orders. When David finds out, he tells Mike who Kelly is, and Mike can't bring himself to kill David's woman. The agents show up and try to arrest David, but he and Mike beat them up.
They trade plane tickets and say their farewells. Steve is holding a house party which David infiltrates to rescue Kelly. Scanlon gets one of Steve's neighbors (Ken Marino) to wear a wire to get a confession out of Steve. David breaks Kelly out of the shed where she is being held, and he steals Steve's BMW to make a getaway. Unfortunately, David's plan to burst out the gates backfires. Steve catches him and tries to beat him up, until David realizes he is near the police van with the detectives waiting for their confession. David tricks Steve into admitting that he was the mastermind of the whole plan, giving the detectives enough reason to arrest him.
David and Kelly say goodbye just before they are hauled off to prison. Once David gets to prison, he is applauded by all the inmates for stealing the biggest amount of money in U. S. history. The story of the robbery becomes nationwide news, but it turns out that David stashed away $2 million in a barrel that he rolled into a lake.
After serving seven years, Mike picks David up, and they head off to visit Kelly. The final text states that Steve Chambers served 11 years in prison, and he now owns a fitness center. David Ghantt served 11 years and he occasionally works as a film consultant. The Loomis Fargo robbery was one of the biggest heists of all time, and $2 million of the stolen money remains unaccounted for to this day..