As a child, Colin Sullivan (Matt Damon) had been introduced to organized crime by Irish-American mobster Frank Costello (Jack Nicholson) in the Irish neighborhood of South Boston. Over the years, Costello grooms him to become a mole inside the Massachusetts State Police, until Sullivan is accepted into the Special Investigations Unit, which focuses on organized crime.
Before graduating from the police academy, Billy Costigan (Leonardo DiCaprio) is recruited by Captain Queenan (Martin Sheen) and Staff Sergeant Dignam (Mark Wahlberg) to go undercover, as his family ties to organized crime make him a perfect infiltrator. He drops out of the academy and does time in prison on a fake assault charge to increase his credibility.