Pogacar's UAE Team Emirates dominated the stage from Zalec to Celje, and he broke away on the final second-category climb.
The 22-year-old Slovenian crossed the line to win by 1:22 after a 22-kilometre solo ride.
Matej Mohoric (Bahrain Victorious) came second while Pogacar's teammate Diego Ulissi rounded out the podium in a sprint finish for the chasing group.
"This stage was already hard two years ago and it was even harder today," Pogacar said in the aftermath.
"I felt super good so I tried to go full gas on the climb.
"I got a gap and then after the descent; full gas to the finish and I made it.
"I really like this stage. It's a classic one for the race. I tried today and it was a success.
"I didn't think it would be such a good advantage in the end. I'm really happy to take this win."