
Zillah Byng-Maddick, chief financial officer, will fill in for King while the company looks for a permanent replacement.
King issued a statement saying: "I have enjoyed five exciting and successful years working with an outstanding team at TMG.
"We have been on an amazing, transformational journey and while I am sorry to be leaving, the business needs a leader to commit long term to the next stage of the company's development."
King joined TMG in May 2007 from his then role as chief executive at Australian classifieds business, Trading Post.
Prior to this, he was general manager of online advertising of Sensis Pty, the group that owns Trading Post.
Tom Hall, chairman of the TMG board, said: "We are tremendously grateful for everything John has achieved at TMG. During his time as chief executive, the group has been widely recognised as providing one of the world's most successful examples of transition from print to digital publishing.
"He leaves the company in excellent shape as it moves on to the next stage of its development."
TMG publishes more than 70 classified titles including Auto Trader, Ad Trader, Biker Trader and Auto Freeway.
Auto Trader recently launched a campaign promoting its digital credentials.