Jim has held the position since February 2014, when a management restructure saw the Mail and Record’s editorship split.
Prior to that, Jim had served as the Mail’s executive editor since 2012.
He first joined its newsdesk in 2000, having worked for the Edinburgh Evening News, Scotsman and Daily Record.
Jim is due to leave the paper at the end of next week.
A spokesman for parent company Trinity Mirror said: “We can confirm Jim is stepping down as editor of the Sunday Mail, with effect from 4 September.
“Jim’s fearless, campaigning journalism saw the Mail win Newspaper of the Year in 2014. We wish him every success in his future career.”
No announcement has yet been made about his successor.