Primož Roglič won a gold medal at Tokyo 2020 in the men's road time trial ©Getty Images

Defending champion Primož Roglič won a thrilling stage 11 of the Vuelta a España after snatching victory away from Denmark's Magnus Cort Nielsen in the mountainous city of Valdepeñas de Jaen.

The Jumbo-Visma all-rounder recovered from losing the red jersey during the previous stage after he crashed following an unnecessary attack on a descent.

The Slovenian managed to open up a three second gap on his opponents when he crossed the line on a short but steep uphill finish.

Spaniard Enric Mas finished second after going shoulder to shoulder with Roglič on the climb, with his Movistar teammate, Miguel Angel Lopez of Colombia, taking third at five seconds.

The other general classification contenders finished exhausted and at least seven seconds down, with Lopez's compatriot Egan Bernal of the Ineos Grenadiers finishing ninth.

"It was a hard stage, short but super hot again," Roglič said, as reported by BBC Sport.

"I was suffering a lot but luckily I had enough to win at the end.

"It's always nice to win - you never know when'll be your last victory.

"It was a nice finish with steep uphill, which normally I can do well, so it was a nice challenge and the team did an amazing job, pushing really hard throughout the day."

The result sees Roglič climb to third in the general classification standings while Odd Christian Eiking of Norway remains in pole position despite his tenth place finish.

Stage 12 of the tour will see riders travel from Jaén to Córdoba in a 175km race which is expected to last around four and a half hours.

It is a balanced stage and could tempt some competitors into a breakaway before they meet two steep climbs at Alto de San Jerόnimo and the Alto del 14%, an 8.4 kilometre climb that finishes in Cordoba.