Luis Suarez scored one goal and made another as Ernesto Valverde's men, who had won their previous six games in all competitions, came from behind to lead at Anoeta.
However, Alexander Isak's 62nd-minute strike earned fourth-placed Sociedad a deserved share of the spoils, meaning Real Madrid now have the chance to move two points clear at the top of LaLiga with victory at Valencia on Sunday.
Barca could have few complaints about their failure to win, having been outplayed for large parts of an entertaining contest, and Ernesto Valverde's men will know they must deliver an improved display against Madrid in their next match.
Sociedad moved ahead after 12 minutes when Sergio Busquets was penalised for tugging Diego Llorente's shirt at a corner and Mikel Oyarzabal calmly sent Marc-Andre ter Stegen the wrong way from 12 yards.
The hosts remained in the ascendancy for much of the first half, but Barca pulled level in the 38th minute courtesy of a devastating break. Sociedad were left short of bodies at the back after Llorente was caught under the ball near the halfway line and Suarez drove forward before slipping in Antoine Griezmann, who clipped a deft finish into the bottom-right corner in front of his former home fans.
Imanol Alguacil's men were again guilty of slack defending as Barca took the lead four minutes into the second half. A glorious lofted pass from the previously unimpressive Busquets put Lionel Messi clear and he selflessly squared the ball to leave Suarez with the simple task of finding an open goal.
Griezmann and Gerard Pique came close to adding a third for Barca, but Sociedad soon hit back, Isak converting a simple rebound after Ter Stegen had needlessly parried a Nacho Monreal cross into the striker's path.
Monreal required treatment and a new shirt after comically injuring himself celebrating the goal. He and Oyarzabal attempted to bump chests but instead collided face to face.
Neither side could find a winner thereafter, home substitute Willian Jose coming closest when he fired a close-range shot into Ter Stegen's legs with the keeper grounded, while Barca saw an injury-time penalty appeal waved away when Pique and Llorente tumbled to the floor together contesting a Suarez cross.