Barcelona travelled to Madrid with the aim of keeping up their 100 per cent record at the start of the season. Before the game, coach Ernesto Valverde insisted his side take nothing for granted against the defensively aggressive Getafe.
And the hosts did not disappoint. Striker Jorge Molina was first to fire a warning shot early on when he went for a strike on the turn but Ter Stegen, making his 100th appearance for the Camp Nou outfit, got down to collect.
Getafe continued their strong start, breaking down Barcelona's build-up play early on. To make it harder for the Catalans, the dry pitch did not help Valverde's plans to pass the ball around quickly.
Though Barcelona were in control of the ball possession, they were unable to get going. While Getafe keeper Guaita remained untroubled, the hosts had the first clear chance to take the lead.
Shibasaki ran down the left of the area before squaring the ball across the six-yard box with Pique getting his body in to almost turn the ball into his own net. Ter Stegen got a fingertip to the ball before Molina failed to convert from a tight angle at the far post.
Following the shock, Barcelona still failed to respond, and Valverde's woes increased further when Ousmane Dembele went down in pain. On his full La Liga debut, the French youngster held the back of his thigh before he limped off to be replaced by former Everton man Gerard Deulofeu.
While the visitors were not looking as sharp as usual, it was largely thanks to the efforts of a defensively solid Getafe side. The team managed by Jose Bordalas reaped their rewards in the 29th minute, when a long ball into the area was nodded down by Bergara into the path of Shibasaki, who smashed a thumping volley into the top corner.
Having deservedly taken the lead, Getafe increased their defensive lockdown. It wasn't until the dying seconds of the first half that Guaita was forced into action. Messi sent a wonderful free-kick which was heading for the top corner, but for a fabulous save from the keeper.
After the break, Valverde brought on Denis Suarez for a tired looking Andres Iniesta and fifteen minutes of Barcelona dominance ensued before the young Spaniard, who proved hugely influential, levelled the scoring.
Getafe's defence switched off for a split second as Sergi Roberto pegged the ball in from the right for Denis Suarez. The midfielder took one touch before finishing with a fine strike into the top corner.
Since scoring the equaliser, the visitors piled on the pressure in search of a goal to give them the lead. Getafe decided to sit deep trying to force Barcelona into a physical battle, and Valverde brought on Paulinho to give his side more presence when attacking from midfield.
With ten minutes to go, Getafe almost regained the lead when Arambarri got another sight on goal. The midfielder's shot took a deflection off Sergi Roberto before hitting the base of the post, with Ter Stegen stretching hopelessly.
However, Valverde was once again rewarded for his decision from the dugout when substitute Paulinho burst into the box in between Dakonam and Cala before firing his finish across goal and into the bottom corner.
From then on, Barcelona looked to wind the clock down by getting a hold of the ball. The Catalans claimed a crucial three points at the Coliseum Alfonso Perez where they were faced by a combative Getafe who will feel hard done by.