The Springboks asked every question of Ireland.

Time and time again Andy Farrell's side found the answers.

The best thing about this Irish win was the amount of things that went wrong.

In the first 40 minutes they came up against a relentless South African defence that made every tackle and read and played the game on their own terms; territory and possession. But they didn’t panic.

Their bench was tested, and passed with flying colours. Stuart McCloskey, Conor Murray and Tadhg Furlong all succumbed to injuries in an incredibly physical contest. Jamison Gibson-Park changed the game when he came on while Finlay Bealham gave arguably his best showing in an Ireland jersey, right in the centre of a dominant Irish scrum.

While South Africa were winning individual collisions, Ireland’s forwards – as a unit – were immense, particularly with how they shut down the Springbok maul.

Level at 6-6 after a tense first 40 minutes of chess, Ireland struck for two tries early in the second half from Josh van der Flier and Mack Hansen, the second a result of a brilliant counter-attack, which had been instigated by Caelan Doris.

And although Johnny Sexton’s conversions were off target, a penalty seven minutes from time proved to be enough for the win, despite the best efforts of the world champions who had fought back with tries from Franco Mostert and Kurt-Lee Arendse.

The clock had barely hit 60 seconds before Sexton was presented with the easiest of opportunities to kick Ireland in front. A Murray box-kick up the centre of the pitch was brilliantly fielded by Garry Ringrose, and after Steven Kitshoff failed to roll away, it gave the Ireland captain a tap-over penalty, which he converted to make it 3-0.

A mistake off the restart instantly put Ireland on the back foot, and if there was ever any doubt of the challenge South Africa would bring, the 17 phases of rugby they put together in the Irish 22 was an early reminder. It ended with a penalty, Furlong penalised for offside, allowing Willemse tie things up at 3-3 in the ninth minute.

As expected, kicking was currency in the opening quarter, and it was pinning Ireland back. An unprotected ruck saw Jasper Wiese force Murray into a knock-on, but a brilliant double tackle from McCloskey and Doris allowed the latter to win a jackal penalty, and bring Ireland back into the Springbok half.

Moments later, Kolbe saw yellow, but was incredibly fortunate not to see red. The full-back lifted the leg of Hansen and tipped him above the horizontal, before driving him to the ground. The Irish wing appeared to land on his head, but not in the eyes of the officials, who deemed it to be on the back, before sending the Toulon man for 10 minutes in the bin.

Some brilliant defence from Makazole Mapimip killed the Irish attack, and two minutes later the Springboks had a chance to nudge in front after McCloskey was penalised for a high tackle, but Willemse sliced his kick wide to the right.

When they were awarded another penalty in an identical position moments later they went for the corner. For the second time Ireland's maul defence was water-tight, the visitors eventually going off their feet at the ruck to hand possession back to the hosts.

On 31 minutes, the Aviva erupted, but those cheers didn’t last long. Dan Sheehan’s charge-down of a Willemse clearance kick saw he and Jesse Kriel side-by-side racing for the tryline, and while the Ireland hooker got his hand to the ball first, a check with the TMO proved it to be a knock-on.

For the first time, Ireland had momentum, and when Lood de Jager bought Murray’s dummy, it allowed the scrum-half bring Ireland back into the 22. A penalty followed and Sexton obliged with his second kick of the day to make it 6-3.

That passage of play was enough to end the night for both Murray and De Jager. The Munster man was seen wincing as he scampered through that gap in the defence, and he looked dejected as he limped off the pitch, an unfortunate ending to his 100th cap. De Jager, meanwhile, held his arm in a makeshift sling, Mostert replacing him in the second row.

Ireland couldn’t bring their lead into the half-time break though, Kolbe equalising with the final play of the first 40 after an Irish offside. Had it not been for a James Ryan lineout steal moments earlier, the Boks could have been heading for the sheds in front.

When the sides restarted, Furlong had been added to the Irish injury list, a twisted ankle late in the half had him down for some time, and it was no surprise to see Finlay Bealham jog out for the second half, the Connacht man marking his territory instantly to win a scrum penalty.

There were further injury fears when Sexton stayed down injured after a ferocious Kriel tackle, but while he was being treated Gibson-Park and Hansen combined to break into the 22 and force a penalty.

The Irish captain dusted himself off and pointed for the corner, and it proved to be the right call. Sheehan found O'Mahony with the lineout, and the Irish maul did the rest, Van der Flier managing to stay infield as he ground the ball in the corner.

Sexton’s conversion pulled to the left, keeping things at 11-5 on 48 minutes, but just two minutes later they burned their way through the Springboks’ defence for a second try, a double-hit of scores reminiscent of their third quarter against the All Blacks 12 months ago.

Doris led the counter-attack, pouncing on a loose ball before popping to Van der Flier, and after moving play infield Gibson-Park scampered around Kitshoff towards the 22. From there, they just needed simple hands as Beirne, Keenan and O’Brien shipped it one by one to Hansen, who darted over for the try, which was once again missed left by Sexton, the scores now 16-6.

As much as Ireland needed those scores, the game did too, and the visitors started chasing. Just after the hour mark, Kwagga Smith’s quick-tap penalty brought the Boks to the fringe of the 22, but Ireland’s defence stayed true, O’Brien in particular with a crucial one-on-one tackle on Etzebeth.

On 65 minutes they had their breakthrough, Mostert’s long reach making it to the line, after Kolbe and Kriel had been denied in the far corner moments earlier.

Kolbe had a straightforward conversion attempt but it came back off the post, leaving Ireland still five points in front at 16-11.

He was made to pay for it on 73 minutes, Sexton putting Ireland two scores in front with a penalty from the left of the posts after referee Nika Amashukeli pinged two Springboks for offside.

It was never going to be an easy finish though, and after South Africa finally got their scrum going they forced a penalty advantage, which they used to spread the ball wide and send Arendse in for a try.

Again, they sliced the conversion wide, as Ireland brought a three-point lead into the final three minutes, and they didn't let it slip, Andy Farrell's side making a major statement ahead of next year's Rugby World Cup rematch.

Ireland: Hugo Keenan; Robert Baloucoune, Garry Ringrose, Stuart McCloskey, Mack Hansen; Johnny Sexton (capt), Conor Murray; Andrew Porter, Dan Sheehan, Tadhg Furlong; Tadhg Beirne, James Ryan; Peter O'Mahony, Josh van der Flier, Caelan Doris.

Replacements: Rob Herring, Cian Healy, Finlay Bealham, Kieran Treadwell, Jack Conan, Jamison Gibson Park, Joey Carbery, Jimmy O'Brien.

South Africa: Cheslin Kolbe; Kurt-Lee Arendse, Jesse Kriel, Damian De Allende, Makazole Mapimpi; Damian Willemse, Jaden Hendrikse; Steven Kitshoff, Malcolm Marx, Frans Malherbe; Eben Etzebeth, Lood de Jager; Siya Kolisi (capt), Pieter-Steph du Toit, Jasper Wiese.

Replacements: Bongi Mbonambi, Ox Nche, Vincent Koch, Franco Mostert, Deon Fourie, Kwagga Smith, Faf de Klerk, Willie le Roux.

Referee: Nika Amashukeli (GEO).