And a sensational draw means Cristiano Ronaldo and Lionel Messi will face each other in the group stage for the first time.
Messi's Barcelona was drawn from the pot of second-seeded teams Thursday into the group where Ronaldo's Juventus team was already placed as a top seed.
The 35-year-old Ronaldo and the 33-year-old Messi had a long-standing rivalry in the Spanish league when the Portugal star was with Real Madrid, but have never faced each other so early in the Champions League.
Barcelona have not reached the final since their last Champions League triumph in 2015 and will be determined to end a run of just one semi-final appearance in five seasons.
The disastrous nature of their 8-2 defeat to Bayern Munich in last season's quarter-final almost led to Lionel Messi's departure, but the Argentine has since committed to the club for at least another 12 months as he sets his sights on a fifth Champions League medal.
He told Sport in Spain: "After so many disagreements, I would like to bring an end to everything. We all have to be united and assume that the best is yet to come."
Here's who Barcelona will face in the group stages...