Time trials are a necessary evil in pro cycling, but that doesn’t mean we have to like them.

Time trialing is a precise art, requiring incredible focus, power and determination. There’s an undeniable austere beauty to cycling’s race of truth.

There’s only one problem: time trials are boring as hell to watch.

That changed Wednesday in dramatic fashion in Norway. The thrilling race in the elite men’s world championship race proved that time trials can pack a punch.

Wednesday’s time trial will rank among the best and most exciting races against the clock we’ll likely ever see.

Why? A perfect blend of course dynamics, a controversial bike-swap opportunity before a climber’s finale, a world-class field, and a dose of late-race rain, all cheered on by a massive crowd added up to deliver something remarkable.

“The atmosphere was amazing,” dethroned world champion Tony Martin told DPA. “Even if it wasn’t my kind of course, it was one of the best finales I’ve ever raced.”

It isn’t always this way.

Time trials, by their very nature, are the opposite of the raw energy and unpredictable emotion that road racing typically evokes. Without team tactics or bunch theatrics, time trials are metronomic battles against the clock. Beautiful and enthralling in their own way, time trials are generally tedious and uninspiring for almost everyone else.

There have been a few exceptions: Paris in the 1989 Tour de France, or Milan in the 2012 Giro d’Italia. Exception is the keyword. Who else remembers a time trial?

Like it or not, time trials are ascendant in cycling today.

In modern cycling, where power meters, stronger teams, and an ever-more-equal peloton have combined to slowly squeeze the excitement out of the summit finales, time trials are where stage races are won and lost. On a good day, the most a grand tour rider might gain is 20 seconds in a mountaintop finale. In contrast, the differences can be minutes in time trials. That’s why teams and riders invest more time, energy, and training into time trials than any other aspect of racing.

It’s just a shame that no one’s figured out how to make them interesting. Until now, that is.

When organizers of the Bergen world championships offered up the 31km course, people were instantly intrigued. And Wednesday’s nail-biting racing action confirmed it was a time trial unlike any other.

The relatively short distance guaranteed a tight race. The opening 27.6km of the course fit the traditional world’s TT mold. Undulating terrain, some technical corners, a few punchy climbs, but nothing that pure power machines like Tony Martin and Vasil Kiryienka couldn’t turn into molehills. And had it ended there, no one would be buzzing like they are.

Norway’s rugged coastline and technical urban streets served up a tantalizing opportunity for race organizers. Rather than settle for a traditional course, they added a whopper.

It was the inclusion of the hairpin climb up Mount Fløyen — 3.4km at 9.1 percent — that turned drab into dramatic.

The pre-race anticipation was heightened by the introduction of a “bike changeover” zone. Purists rolled their eyes, insisting that by providing riders the opportunity to swap bikes before the final climb simply proved that the course wasn’t in the spirit of what a real time trial should be.

In the end, around 65 percent of the field opted for a bike change. Of the final 10 riders, however, only one — silver medalist Primoz Roglic — decided to swap bikes.

The addition of the “to swap or not to swap” question added another wrinkle of intrigue before what was a very interesting race.

“I am one of those guys who can climb on a time trial bike,” said gold medalist Tom Dumoulin. “I had doubts about swapping the bike, but yesterday we made the decision not to change bikes, and I think it was the right one.”

The crowds were raucous and rowdy, but in a decidedly polite Norwegian way. Everyone respected the rules and did not interfere in any way with the riders. The few who tried to play a Viking’s version of Running of the Bulls were quickly body-checked off the course. Fans cheered, applauded, and rejoiced in their sea of red Norwegian flags. It was 10-deep all the way up the final climb, as big as any crowd you’d see at Alpe d’Huez or the Kapelmuur.

The organizers and the UCI deserve kudos for embracing this idea. You can’t have a course like this year every year, but on Wednesday, Bergen delivered something rare: a time trial that was worth watching.