The result means the Catalans (The side of Ronald Koeman) blew the chance to go top of LaLiga with five matches left.
Lionel Messi opened the scoring, before missing a big chance to make it 2-0.
Darwin Machis and Jorge Molina were left in acres of space to turn the game on its head in the second half.
Barca’s second loss in 23 matches, means they are no longer in charge of their own destiny in the title race.
“We lost our focus in the second half and made errors at the back,” Ronald Koeman told Movistar.
“We need to accept the fact we’ve lost, that’s the reality of things.
“We had chances to win the game, but that’s that. We’ve got five more games to go and each of the sides (in the title race) will have difficulties moving forward.
“We now need to prepare ourselves for Sunday’s game (away to Valencia). We’re still in the mix and have a chance. We need to accept this, move on and prepare for the next one.
“We tried but weren’t able to make many chances when they scored their goals. They closed shop well and we couldn’t create.”