AC Milan will pay 18m euros (£16m) for the loan of Higuain and have the option to make the deal permanent in a year by paying a fee of 36m euros (£32.04m).
Meanwhile, Italy defender Mattia Caldara has left Juve to join AC Milan.
Bonucci, 31, and Caldara, 24, is a swap deal with both transfers worth 35m euros (£31.2m).
Argentina striker Higuain, 30, scored 16 Serie A goals last season.
Higuain, who was linked with a move to Premier League side Chelsea, joined Juve from Napoli for a then domestic record fee of £75.3m in 2016 and scored 40 league goals in two seasons.
Bonucci, 31, spent just one season at the San Siro having joined from Juve for £35.1m last summer.
A Juventus statement said: "After spending seven wonderful years in black and white, Leonardo Bonucci has returned to the club following a season at AC Milan.
"Both Juventus and Bonucci are ready to start winning things again together."
accurate football prediction worldwide