Lamine Yamal and Raphinha struck to earn Barcelona a 2-0 win over Real Sociedad on Monday, taking their team second, a point above Catalan rivals Girona.
Defeat is a setback to La Real's ambitions of playing Europa League football next season, leaving them seventh behind Real Betis, who won on Sunday, reports AFP.
Last season's champions Barcelona are playing for nothing but pride in the final weeks of a disappointing campaign, and finishing above high-flying minnows Girona is imperative to achieve even a modicum of that.
Real Madrid sealed their title win at a canter after Barcelona were beaten 4-2 by Girona little over a week ago.
Barca's brightest light Yamal opened the scoring after 40 minutes and Raphinha added a late penalty to seal the win.
"La Real are a great team, it's an important victory for us, we had a good game in general," Barca coach Xavi told Movistar. Xavi benched Uruguayan centre-back Ronald Araujo, bereft of form this season and whose
red card against Paris Saint-Germain contributed heavily to their Champions League collapse.
With Madrid swiping La Liga back off the Catalans, they end the season trophyless and licking their wounds.
Xavi, who will stay in charge next season after ditching his exit plan, started defender Inigo Martinez in place of Araujo and Pedri Gonzalez in midfield.
The Canary Islander is still building form and fitness after a string of injury problems ahead of Euro 2024, and helped Barca control the game.
Striker Robert Lewandowski was unusually active in his team's pressing, perhaps motivated by the race to finish as La Liga's top scorer.
At the other end Marc-Andre ter Stegen denied Sheraldo Becker after he burst beyond Pau Cubarsi, but the Suriname international had pushed the young defender in any case.
Shortly afterwards Becker got in behind Barcelona's high line again and this time fired home, but was correctly flagged offside.
Real Sociedad stopper Alex Remiro saved well from Yamal after the 16-year-old winger combined with Ilkay Gundogan to break into the area.
Raphinha struck the post towards the end of the first half with a long-range effort and Gundogan turned the rebound over after it fell to him at an awkward angle.
It was a warning Real Sociedad did not heed with Yamal sending Barca ahead soon after.
Lewandowski fed Gundogan well with a low through-ball and the German teed up the winger to steer home his fifth league goal of the season.