Barca played 45 minutes with 10 men but managed to extend their record undefeated streak in the top flight to 42 matches, a record that stretches back to April 2017.
In Andres Iniesta's last Clasico, Luis Suarez gave the Catalan giants an early lead by turning in a terrific right-wing cross from Roberto, but the advantage did not last long as Madrid hit back in the 14th minute.
Cristiano Ronaldo - substituted at half-time due to injury - equalled Alfredo Di Stefano's record of 18 Clasico goals for Madrid by tapping in a clever Karim Benzema header back across goal.
Madrid's chances of winning were boosted by Roberto's red card for appearing to strike Marcelo in the face late in the first half, although Gareth Bale could have also been dismissed after seeming to stamp on the back of Samuel Umtiti's leg.
Although they were a man light, Barca regained the lead thanks to a sensational Lionel Messi goal - his 26th in this fixture - but Madrid felt Suarez fouled Raphael Varane in the build-up.
Bale had the final say by getting his first LaLiga Clasico goal with a 20-yard strike to claim a point for Madrid, who stay 15 points behind their irrepressible rivals.
Suarez missed an early chance after being fed by Messi, but the Uruguay forward put Barca in front in the 10th minute.
Roberto raced away down the right after being sent clear by Suarez, who timed his run to the back post perfectly to turn the deep cross past Keylor Navas with a low volley.
The lead did not even last five minutes, though, Ronaldo inevitably central as he made it 12 goals in his last 12 visits to Camp Nou.
Ronaldo started the move by teeing up Toni Kroos on the overlap, the Germany midfielder's cross nodded into the middle by Benzema and the Portugal superstar tapped in on the line despite the close attention of Gerard Pique.
Madrid were stamping their authority on the contest, Ronaldo heading over and drilling wide either side of being denied at close range by Marc-Andre ter Stegen.
The first half ended with referee Alejandro Jose Hernandez Hernandez in the thick of the action, Suarez and Sergio Ramos booked before Messi earned a yellow for a late foul on the Madrid captain.
Tempers boiled over before the break as Roberto saw red for lashing out at Marcelo, the Barca full-back seeming to push his hand into his opponent's face.
Ronaldo, who appeared to be injured in the process of scoring, was replaced by Marco Asensio at half-time, while Nelson Semedo plugged the gap left by Roberto by coming on for Philippe Coutinho.
Madrid were leaving too many gaps, though, and Barca went back in front in the 52nd minute thanks to Messi's first home league Clasico goal in five matches.
Suarez seemed to trip Varane as he robbed the defender wide on the left, but the referee waved play on and he passed for Messi to cut inside two challenges and smash a shot into the bottom-left corner.
Barca thought they had extended their lead through Suarez, only for the goal to be disallowed for a marginal offside in the build-up, and Iniesta, seemingly set for a switch to the Chinese Super League, was then withdrawn to a standing ovation.
Navas did well to stop Messi wrapping up the points after the Barca star raced clear and that save proved key as Bale struck in the 72nd minute.
Asensio fed the Wales international on the edge of the box and he bent a first-time strike out of Ter Stegen's reach to level for the Champions League finalists.
Madrid felt Jordi Alba brought Marcelo down in the box but the referee waved away the appeals, before Messi missed two late openings as the last Clasico of the season ended with the spoils shared.