The 1949 film starring James Cagney that features the famous line “Top of the world, Ma!” is White Heat.
Cagney plays Cody Jarrett, a volatile and increasingly unstable gang leader whose relationship with his domineering mother, Ma Jarrett, shapes much of the story. The line comes during the film’s explosive climax, when Cody climbs atop a burning gas-storage tank and triumphantly shouts, “Made it, Ma! Top of the world!”
Directed by Raoul Walsh, White Heat blends gangster-film conventions with psychological intensity and prison-break plotting. Cagney’s performance helped redefine his screen image: unlike the relatively controlled criminal he played in The Public Enemy, Cody is paranoid, violent and prone to debilitating headaches.
The quote is sometimes shortened to “Top of the world,” but the full line belongs to White Heat. The other options are also notable Cagney films, especially Yankee Doodle Dandy, which is a musical biography rather than a crime thriller.