Young substitute Oscar Melendo beat Jasper Cillessen with two minutes to go as Espanyol inflicted Barcelona's first defeat since August.
Oscar Melendo's late goal saw Espanyol snatch a 1-0 win and inflict a first defeat on Barcelona since August, after Lionel Messi failed to score a penalty in the first leg of the Copa del Rey quarter-finals.
A dominant Barca looked as though they would have to settle for a goalless draw after Messi saw his second-half spot kick saved by Diego Lopez on Wednesday, but little did they know that things were to get even worse.