An unorthodox lobbed free-kick unsettled the Barcelona defence and Lafita brought the ball down, held off the attention of Pedro and then lashed a shot across goalkeeper Jose Pinto and into the left corner.

The goal was initially ruled out by the linesman, who appeared to suggest that Lafita had handled the ball, but referee Jose Teixeira intervened and the decision was overruled, as the visitors went to the break on level terms after Alexis wasted a late chance.

Alexis was denied by the crossbar early in the second half, despite failing to meet Alves' swinging cross from the right with his head, almost scoring with his shoulder after significant pressure from defender Rafa.

The chances kept coming for Barca, as Pedro was denied by Getafe goalkeeper Julio Cesar after an excellent dribbling run from Messi, and their persistence was eventually rewarded in the 67th minute.

The goal followed a neat team move, with substitute Cesc Fabregas' ball finding Pedro, and although his shot was blocked, Alexis was on hand to fire the rebound in with his left foot.

Fabregas and Alves had further opportunities to extend Barca's lead, before Messi lobbed onto the roof of the net, while at the other end, Pablo Sarabia was guilty of missing a great chance with 10 minutes left.

With Barca left vulnerable after a quick Getafe counter-attack, Sarabia could only fire a volley straight at Pinto.

But it mattered little, as Lafita's late effort boosted their survival hopes and shattered Barcelona dreams.