Giannis Antetokounmpo finished with 33 points and was a tough matchup in the paint for Milwaukee, which dropped 2 1/2 games behind the fourth-place Hawks in the Eastern Conference.
Atlanta has won eight of nine. The Bucks have dropped three of five.
Dunleavy, in his second game since arriving in a trade last week with Cleveland, had his first 20-point performance since a first-round playoff game for Chicago on April 30, 2015.
Antetokounmpo has scored at least 30 points in eight games in a breakout season.