The full-back, who turns 31 in June, won his 100th cap for his country in the Six Nations defeat by Ireland earlier this month but limped off injured and missed their final game against Italy.
Hogg, who signed his first professional deal with Glasgow Warriors in 2011, said a "new career beckons".
"I don't feel my body can achieve the standards that I set myself for much longer," he said.
"I've always wanted to finish at the top end of the game. After the tournament, a new career beckons and I will attack it in the same manner as I play the game."
Hogg made his Scotland debut during the 2012 Six Nations and was selected for the British and Irish Lions on three successive occasions (2013, 2017 and 2021).
His 2017 tour was cut short by a facial fracture, but in 2021 he gained two Lions Test caps against South Africa.
His relationship with present Scotland coach Gregor Townsend has not been plain sailing - there have been disciplinary issues and he was replaced as captain last October by Jamie Ritchie.
He has enjoyed club success, winning the 2015 Pro12 title with Glasgow and a Premiership and European Champions Cup double with Exeter in 2020.
This year's World Cup in France will be his third should he play in it.
"Rugby has allowed me to meet some incredible characters, make lifelong friends, travel the world and be part of some unbelievable experiences that I will cherish forever," said Hogg.
"Knowing what lies ahead, I have a real hunger to play the best, most enjoyable rugby of my career, finishing the season strongly with Exeter Chiefs before attacking the opportunity we, as a nation, have in France."