Nick Kyrgios entertained but left empty-handed again as Rafael Nadal won a compelling fourth-round contest at the Australian Open.

Kyrgios, a huge basketball fan, was close to tears as he walked onto Rod Laver Arena wearing Kobe Bryant’s LA Lakers vest in tribute to the star, who died on Sunday.

And initially it appeared the emotion of the occasion, coupled with physical fatigue after his four-and-a-half-hour battle against Karen Khachanov two days before, would prevent him making a fight of it.

But Kyrgios, driven by his efforts in raising money for victims of the wild fires, has been keen to show Australia that he cares on court as well as off it.

He roused himself at the start of the second set and, had he taken an extraordinary third set, the outcome might have been different but, as with their clash at Wimbledon last summer, it was Nadal who prevailed 6-3 3-6 7-6 (6) 7-6 (4).

That contest had a real edge to it after some very public needle, with Nadal accusing Kyrgios of lacking respect following a feisty match in Acapulco and the Australian branding his opponent “super salty” in an interview on the No Challenges Remaining podcast.

Both men had been more conciliatory in the build-up to this one and the match itself took centre stage.

Nadal leapt in the air when Kyrgios’ final forehand landed in the net, and it is he who moves through to a quarter-final against Dominic Thiem on Wednesday.

Having been very subdued in the first set, Kyrgios made a statement at the start of the second by standing ready to serve well before umpire James Keothavong had called ‘time’.

It was an important moment. Nadal pressed for an immediate advantage only for Kyrgios to save a break point with a rally featuring a wholly-unnecessary tweener.

It summed up the difference in their philosophies and Nadal’s unusually passive response was perhaps because the idea of playing a trick shot at such a moment is unfathomable to the Spaniard.

Australian Open Tennis
Nick Kyrgios came on court wearing a shirt in tribute to Kobe Bryant (Andy Wong/AP)

Three games later, Kyrgios broke, leaping and punching the air after a desperate forehand pass dropped in.

Although the Australian could only laugh at the brilliance of some of his opponent’s shots, Kyrgios’ serve was really firing and he held relatively comfortably to level the match.

The third set was the peak of the contest, with Kyrgios doing all he could to flummox Nadal, mixing explosive ground strokes with slow balls, forehand slices, drop shots, an underarm serve and everything in between.

The Spaniard’s game was certainly disrupted but Nadal is arguably the strongest athlete mentally in all of sport and it was he who eventually took the set on a tie-break.

Australian Open Tennis
Nick Kyrgios battled back after losing the first set (Lee Jin-man/AP)

There was plenty more drama, with Kyrgios smashing a racket and handing it to a fan then missing a 135 miles per hour second serve at 5-5.

Nadal, seemingly distracted by a crying baby, double-faulted on his first set point but he created a second and took it when Kyrgios slapped a forehand into the net.

The 24-year-old, who was looking to reach his first grand slam quarter-final for five years, then double-faulted again to drop serve in the third game of the fourth set, and finally Nadal seemed to have the breathing space he needed.

But the world number one played a tentative game serving for the match at 5-4 and a mighty forehand from Kyrgios earned him the break back.

The home favourite, for that is certainly what he was here, saved two break points to ensure he would have a shot at another tie-break, but a fluffed drop shot at 3-4 cost him dearly.