The story revolves around three roommates, journalist Tashi (Imran Khan), photographer Nitin Berry (Kunaal Roy Kapur) and cartoonist Arup (Vir Das), leading an unkempt and debt-ridden life in a shoddy apartment in Delhi. Tashi's ditzy fiancée, Sonia (Shenaz Treasurywala), is an air hostess who agrees to deliver a package for Vladimir Dragunsky (Kim Bodnia) to Somayajulu (Vijay Raaz), without realizing its contents or that Somayajulu is a gangster. Sonia asks Tashi to deliver the package. Tashi, in turn, asks Nitin to do so. But Nitin is unable to do so as he is suffering ' Delhi Belly'. Nitin hands Sonia's package to Arup for delivery to Somayajulu, along with a package containing his stool sample for delivery to Nitin's doctor. Arup mixes up the two bags. Somayajulu, furious, tortures Vladimir to find his package.
Meanwhile, Nitin photographs his landlord with a prostitute. He sends an envelope with the photographs to his landlord to blackmail him. Tashi is with Sonia, when his colleague Menaka (Poorna Jagannathan) calls him on the pretext of work. When he reaches the place he realizes that it is just a party and Menaka called him just to have fun. Menaka's ex-husband Rajeev sees them together and punches Tashi in the eye in a fit of jealousy. Tashi retaliates and knocks Rajeev out. As Tashi and Menaka leave they are chased by a furious Rajeev and his friends who shoot at them. The duo barely manage to escape.
Vladimir informs Somayajulu that the mix-up must have been caused by Sonia as she didn't know what she was carrying in the package. Somayajulu calls Sonia, informs her about the mix-up and asks her to give him the address of the person who had delivered the package. When Tashi arrives into his apartment, he walks into Somayajulu who has Arup standing on a stool with a noose around his neck. On hard interrogation, Somayajulu discovers the mix-up and realizes that the package must be with Nitin's doctor.
Nitin gets the package from his doctor's office, wherein Somayajulu finds his thirty diamonds hidden inside. Upon recovering his booty, he orders his henchmen to kill the three roommates. One of them is about to shoot Tashi, when another kicks the stool on which Arup was standing to hang him. Luckily for the roommates, the ceiling of the apartment collapses, since it can't take Arup's weight. The cave-in knocks out Somayajulu and his men, leaving one with broken arms. Tashi, Arup and Nitin escape with the diamonds and spend the night at Menaka's place. The next day they sell the diamonds to a local jeweller.
As the roommates prepare to get out of town with the money, they get a call from Somayajulu who has kidnapped Sonia. He threatens to kill her if they don't return the diamonds. The trio try to buy back the diamonds from the jeweller, who demands double the sale amount.
Without the money, Tashi comes up with a plan. Nitin, Arup, Tashi and Menaka disguise themselves in burqas and rob the jeweller, leaving him the bag of money. They flee in Tashi's car with the police on their tail and go to the hotel where Somayajulu is holding Sonia. As they are about to make the exchange with Somayajulu, the police arrive at the hotel room. There is a shoot-out between the police and Somayajulu's gang.
Nitin, Arup, Tashi and Sonia, who had hit the floor during the gunfight, are left as the only survivors. Menaka, who by now realises that she likes Tashi, is upset to learn about his engagement and walks away from him. Tashi breaks off his engagement to Sonia. Later, it is revealed that Nitin did not return the cash to the jewellery store owner, and had kept most of the money for himself (whereupon he abandons blackmailing the landlord). The film ends when Menaka comes to the roommates' apartment to return Tashi's car's hubcap lost while escaping from Rajeev. Tashi jumps into her car through the open window and kisses her passionately.
Producer-actor Aamir Khan is seen dancing in a song and dance performance as the credits start rolling.