The match's breakthrough arrived inside the first minute, with Raphinha racing onto a pass from Fermin Lopez before rounding Bayern goalkeeper Manuel Neuer and finishing into the back of the net; Joshua Kimmich did his best to block the pass, but Raphinha broke clear and made no mistake, with the Catalan giants getting off to an incredible start.
Bayern answered back in the 18th minute, though, with Harry Kane converting a cross from Serge Gnabry, and it was an incredibly open match, with both sides looking vulnerable in defensive areas.
Barcelona were back ahead in the 36th minute of the contest, with Robert Lewandowski converting into an empty net after the lively Fermin had delivered towards him.
Bayern wanted a free kick, with Fermin leaning onto Kim Min-jae, who had got underneath the ball, but the referee was happy for the play to continue and VAR agreed, as Lewandowski netted against his former club.
Barcelona then made it 3-1 in the closing stages of the first period, and it was Raphinha again, with the Brazilian dribbling into the Bayern penalty box before curling a stunning effort past the reach of Neuer to score his eighth goal of the campaign.
Raphinha completed his hat trick in the 56th minute, again racing behind the Bayern backline before firing one into the bottom corner, with the away side's defenders again unable to get near him.
The result has seen Barcelona move into 10th position in the Champions League table, boasting six points from their three matches in the league phase, but struggling Bayern are now down in 23rd, having only picked up three points from three games.
BARCELONA VS. BAYERN MUNICH HIGHLIGHTS
Raphinha goal vs. Bayern Munich (1st min, Barcelona 1-0 Bayern Munich)
Barcelona incredibly take the lead inside the first minute, as Raphinha races onto a pass from Fermin before take it round Bayern goalkeeper Neuer and finishing into the back of the net. Some start from the hosts!
Harry Kane goal vs. Barcelona (18th min, Barcelona 1-1 Bayern Munich)
Bayern level the scores in the 18th minute of the contest, and the goal comes from England captain Kane, who meets a cross from Gnabry to make it 14 goals in all competitions this season.
Robert Lewandowski goal vs. Bayern Munich (36th min, Barcelona 2-1 Bayern Munich)
Barcelona regain the lead in the 36th minute, with Lewandowski finishing into an empty net after Fermin managed to poke the ball towards him; Bayern want a free kick for a foul on Kim, but the goal is given.
Bayern boss Vincent Kompany is extremely unhappy on the touchline.
Raphinha goal vs. Bayern Munich (45th min, Barcelona 3-1 Bayern Munich)
Oh my word - that is some goal. Barcelona have their third and Raphinha has his second, as the Brazilian works his way into the Bayern box before curling one into the far corner of the net. Stunning shape on that strike!
Raphinha goal vs. Bayern Munich (56th min, Barcelona 4-1 Bayern Munich)
Raphinha has his hat trick, with the forward smashing one into the bottom corner after again breaking behind the Bayern defence; the Brazilian has been absolutely unstoppable tonight.
MAN OF THE MATCH - RAPHINHA
Raphinha has now scored nine goals and registered eight assists in 13 appearances for Barcelona this season, with the Brazilian in stunning form under new head coach Hansi Flick, and he was absolutely electric against Bayern.
The attacker's first of the night was brilliant, showing excellent composure to finish into the back of the net, but his second and third were exceptional, wonderfully curling the ball into the far corner, before smashing one past Neuer to make it 4-1, and Bayern just could not deal with the ex-Leeds United forward.
BARCELONA VS. BAYERN MUNICH MATCH STATS
Possession: Barcelona 39%-61% Bayern Munich
Shots: Barcelona 12-11 Bayern Munich
Shots on target: Barcelona 4-3 Bayern Munich
Corners: Barcelona 5-5 Bayern Munich
Fouls: Barcelona 11-10 Bayern Munich
BEST STATS
WHAT NEXT?
Barcelona have the small matter of a trip to Real Madrid in Spain's top flight on Saturday; Flick's side are currently top of the La Liga table, three points ahead of the reigning champions after 10 games of the season.
Bayern, meanwhile, will be aiming to make it successive victories in Germany's top flight when they head to Bochum on Sunday afternoon; Kompany's side are currently top of the Bundesliga table, level on points with second-placed RB Leipzig.