After Sociedad had taken a deserved early lead from the penalty spot, Barcelona bounced back through Antoine Griezmann and Luis Suarez but an error from goalkeeper Marc-André ter Stegen allowed Alexander Isak to stab home an equalizer.
This was always going to be an entertaining clash, with La Real riding high in fourth place after impressing all season.
The early warning signs were there for Barcelona on Saturday, as rangy Sociedad forward Isak sliced through its defense and set up Mikel Oyarzabal, who opted to cross when perhaps he was better placed to shoot.
However, it wouldn’t be long before La Real got the goal its early dominance deserved.
Eagle-eyed referee Antonio Rojas spotted Sergio Busquets’ pull on Diego Llorente’s shirt and, following a brief pause for confirmation from VAR, pointed to the spot.
Oyarzabal, Sociedad’s 22-year-old captain, stepped up and coolly waited for Barcelona Ter Stegen to move before slotting it to his right.
Martin Odegaard was the bane of the Barcelona defense inside the opening period; his silky passing was carving holes in the Catalan back line time and again.
The young Norwegian was signed by Real Madrid at the age of just 15 but has so far failed to live up to the enormous potential many believed he had.
However, now 20 years of age, this season Odegaard has started to show signs of the promise that convinced Real Madrid to part with $9.5 million for him in 2015.
His dancing feet were one of the highlights of the first half; on one occasion, he evaded four Barcelona defenders in the penalty area before Gerard Pique managed to hack clear his cross into the box.
But with a front three of Lionel Messi, Luis Suarez and Antoine Griezmann, Barcelona is never out of the game.
In the blink of an eye, Suarez won the ball in midfield and slipped Griezmann through on goal for the Frenchman to deftly dink the ball over the onrushing Alex Remiro and into the far corner.
It was harsh on Sociedad but Barcelona was in no mood to feel sorry for its opponent and less than four minutes into the second half, Suarez compounded the host’s misery.
Messi ran onto Busquet’s pinpoint pass over the top and squared the ball for his Uruguayan teammate to score the easiest of tap-ins.
But it’s no fluke that these Sociedad players have lifted the club to fourth in La Liga this season and they believe they can match any team in the league.
Buoyed by the relentlessly noisy home fans, Sociedad pressed for an equalizer and was rewarded just after the hour-mark when an uncharacteristic error by Ter Stegen allowed Isak to tap the ball into an empty net.
There was some controversy in the closing stages, as Pique went down in the penalty area and was adamant he had been fouled by Llorente as he tried to head home the winner.
After some VAR consultation, his appeals were waved away and the visiting side had to settle for just a point from an enthralling game.
The result means Real Madrid can leapfrog its rival at the top of the league if it beats Valencia Sunday.