Following fellow Wimbledon champion Serena Williams on Centre Court, Roger Federer flirted with disaster in the shape of Alejandro Falla, but ultimately pulled through, 6-3, 5-7, 6-3.

Federer has spoken in the past about how quickly and devastatingly a best-of-three sets match can get away from a player. The world No. 1 was on the verge of a simple straight-sets victory to open his quest for his first gold medal in singles before a determined fightback from Falla saw him taken to a third. Falla, who has lost to Federer in all five of their previous meetings—one of which came at Wimbledon after leading by two sets—earned two break points with Federer serving at 1-1 in the first set, but missed on both. It was a sign of things to come, and for almost an hour it was one-way traffic in Federer’s favour.

Federer broke for 5-3 after a lucky netcord gave him the advantage in the point, then served the set out at love. Despite a high first-serve percentage from Falla and a consistent mix of pace and spin, Federer was largely dictating points with his forehand and throwing in perfectly-executed drop shots from both wings. At 3-3 in the second, Federer opened up the game with a backhand pass as Falla came into net, then broke as the Colombian netted a solid return. With Falla serving to stay in the match at 3-5, a clean backhand return winner earned Federer three match points and victory was all but assured.

It was the ‘but’ that proved crucial, however, as Falla saved all three of those points, then proceeded to slot a backhand winner past Federer for a break point as the Swiss served for the match. It seemed that Federer had averted danger when he struck a cross-court forehand winner, but a correct challenge from Falla got him back on serve. Caught off-balance and perhaps haunted by the spectre of his 2010 encounter with Falla that had him teetering on the brink off defeat, Federer squandered three more break points as Falla served at 5-6, then shanked a forehand badly to drop the second set.

Federer broke to lead 1-0 in the third set, but was swiftly pegged back after Falla hammered a forehand down the line to catch the champion off guard. The match was back on level terms at 2-2. Struggling to get out of his own way against an inspired opponent, Federer retreated into more patient play, content to wait for the error from Falla. It paid off when Falla served at 3-3, as an excellent half-volley pick-up earned Federer a break point, then he did just enough in the next point—going back behind his opponent—to draw the error and the break.

Federer held that advantage for three match points on Falla’s serve at 3-5, and this time there was no mistake—or rather, there was, and it came from Falla, as he put a backhand down the line wide. It will be a relieved Federer who moves on to the second round to face Julien Benneteau.

—Hannah Wilks