Roglic, one of the race favourites after winning all three races he has entered this season, clocked 12 minutes 54 seconds over eight kilometres from Bologna to the top of the San Luca hill.
“I’m in very good condition and am very satisfied by my performance and by the time I gained over my opponents,” the 29-year-old Roglic told reporters.
He beat Simon Yates by 19 seconds after the Mitchelton-Scott rider, who had warned that his rivals should be scared of him, looked impressive in the final two-kilometre climb.
Home favourite Vincenzo Nibali was third, 23 seconds off the pace as the Bahrain-Merida leader got off to a decent start in his quest for a third Giro title after triumphing in 2013 and 2016.
Tom Dumoulin (Sunweb), a time trial specialist, was left disappointed to finish fifth, 28 seconds behind Jumbo-Visma’s Roglic and on par with fourth-placed Miguel Angel Lopez (Astana).
“I thought I had managed my effort well,” said Dumoulin, who had no indication of his opponents' form after being the first rider to go down the starting ramp.
“I don’t understand why it did not work. It’s not a good start to the Giro.”
Yates, who last year looked set to win the race when he crumbled on the last mountain stage, decided to depart among the last starters despite possible rainfalls and the choice paid off.
After a slow start, the Vuelta champion produced a massive effort in the tifosi-packed climb up San Luca.
“It was the tactic, I could not go full gas all the way,” said Yates.
“There’s not been a gap between the main favourites, expect for Roglic, which everyone was kind of expecting, really.”
Sunday’s second stage is a mostly flat 205km ride from Bologna to Fucecchio.