The lead role was originally offered to Al Pacino, who declined, feeling it was too similar to the character he'd played previously in Sidney Lumet's Serpico.
The character of Daniel Ciello is based on real-life NYPD Narcotics Detective Robert Leuci. Leuci's testimony helped indict 52 corrupt detectives. After he quit the job, Leuci turned novelist and wrote the gritty police dramas "Snitch", "Odessa Beach" and "Captain Butterfly".
Alan King appears briefly in an early scene, chatting with the character played by Jerry Orbach. King had just finished shooting Just Tell Me What You Want (1980) with director Sidney Lumet for the same studio (the then fledgling Orion, originally a subsidiary of Warner).
Sidney Lumet agreed to direct under two conditions: he wanted an unknown actor to play Leuci and he wanted the running time to be at least three hours long. Treat Williams was unknown at the time but the final cut was edited down to 2 hours and 47 minutes.
To prepare for the role, Treat Williams spent a month with New York City police, participated in a drug bust and lived with Robert Leuci, the person on whom his character is based.
The film was budgeted at $10 million but Lumet completed it for under $9 million. At a Guardian Lecture at London's NFT shortly before the film's UK release, he revealed that the studio were furious with him for doing so since it created a major book-keeping problem for them.