Flick's side opened the scoring in the 53rd minute after Dani Olmo drove at Dortmund's defence from the halfway line and played a pass beyond BVB's offside trap to Raphinha, who raced towards Gregor Kobel's goal and finished into the bottom-right corner.
However, BVB drew themselves level in the 60th minute thanks to Serhou Guirassy, who converted a penalty into the bottom-left corner after Pau Cubarsi was penalised for bringing down the striker following Marcel Sabitzer's cross from the right.
Barca retook the lead 15 minutes later when Jules Kounde's cross to the penalty spot from the right was struck at goal by Fermin Lopez, and Kobel only parried it into the path of meets it on the volley with a shot which Kobel does brilliantly to keep out, but can only palm into Ferran Torres, who lashed home from close range.
Though Guirassy managed to take advantage of a poor offside trap in the 78th minute, sweeping home into an empty net after goalkeeper Inaki Pena rushed out, Torres scored his second of the game just seven minutes later following Lamine Yamal's clever reverse pass during a counter-attack.
The victory means that Dortmund are in ninth place with 12 points after six matches and are one point behind eighth-placed Lille, who occupy the final automatic round of 16 qualification spot.
As for Barca, they are almost certain to automatically qualify for the round of 16 given they now second with 15 points with just two points.
Raphinha's finish was exceptional and left Kobel rooted to the spot, but BVB's offside trap was executed so poorly that it is difficult to see the goal as anything other than a significant defensive error.
Though Cubarsi's foul was no doubt soft, Guirassy's finish was calm and composed, and the same can be said of Torres, who should be praised for positioning himself close to goal for a potential rebound.
Barca's offside trap that led to Guirassy's second was just as poorly executed as Dortmund's, but BVB's naivety saw them concede from their own corner, though Torres's finish into the bottom-left corner was still outstanding.
BORUSSIA DORTMUND VS. BARCELONA HIGHLIGHTS
53rd min: Borussia Dortmund 0-1 Barcelona (Raphinha)
Dani Olmo escapes a challenge from Felix Nmecha and plays a pass through to Raphinha and beats Dortmund's poor offside trap before the forward calmly finishes past Kobel.
What were Dortmund thinking?
60th min: Borussia Dortmund 1-1 Barcelona (Serhou Guirassy)
After Pau Cubarsi is penalised for bringing down Guirassy, the striker sweeps the ball home into the bottom-left corner from the penalty spot.
All even in Germany!
75th min: Borussia Dortmund 1-2 Barcelona (Ferran Torres)
Jules Kounde crosses from the edge of the penalty area on the right to cross to Fermin Lopez, who strike at goal and forces Kobel to make a save, but the goalkeeper parries the ball into the path of Ferran Torres, who slams the ball home.
He couldn't miss!
78th min: Borussia Dortmund 2-3 Barcelona (Serhou Guirassy)
Jan Couto pokes a ball past Barca's poor offisde trap to Pascal Gross, who squares to Guirassy on the edge of the box after Inaki Pena rushes out, and the striker has an easy finish into an empty net.
Serhou Guirassy to the rescue!
85th min: Borussia Dortmund 2-2 Barcelona (Serhou Guirassy)
Barca clear a corner and counter-attack Dortmund, and Pedri finds Lamine Yamal in the final third on the right, before the youngster slips Torres in behind and fires across goal to score his second.
Will that be enough to win?
MAN OF THE MATCH - FERRAN TORRES
After a somewhat underwhelming first half, super-sub Ferran Torres came on and changed the game, demonstrating his ability in the box as an instinctive poacher for his first goal.
For his second goal, Torres' strike into the bottom-left corner was lethal, and he once again displayed his ruthless finishing.
The forward only played 19 minutes, but his two goals have all but secured Barcelona's place in the round of 16, and he is the only candidate for man of the match.
BORUSSIA DORTMUND VS. BARCELONA MATCH STATS
Possession: Borussia Dortmund 45%-55% Barcelona
Shots: Borussia Dortmund 12-13 Barcelona
Shots on target: Borussia Dortmund 2-8 Barcelona
Corners: Borussia Dortmund 2-3 Barcelona
Fouls: Borussia Dortmund 9-10 Barcelona
BEST STAT
WHAT NEXT?
BVB will take on Hoffenheim in the Bundesliga on December 15 at home, and will then travel to face in-form Wolfsburg on December 22.
Meanwhile, Barca will play Leganes in La Liga on Sunday before they host Atletico Madrid on December 21.
Written by
Lewis Nolan