He has worked at several other newspapers across Northern Ireland as well as a stint teaching journalism to students during his career.
In an announcement to Johnston Press staff in Northern Ireland, Rankin said: “I have enjoyed my time editing the News Letter, but I feel it is the right time to move on to a new chapter in my life”.
“I am leaving a paper that’s in good health, with a loyal print readership and a growing digital presence.
“These are exciting times for the business and there is a bright future ahead in the capable hands of a highly dedicated and skilled team of journalists.
“I am proud to have been editor of such a distinguished title with a rich and enduring history and I wish all my colleagues every success in the future.”
Rankin started his career as a reporter with the Armagh Guardian in 1971, before moving on to the Portadown News/Craigavon Times in the mid-1970s.
He worked as a sub-editor with the Belfast Telegraph for 17 years, before a three-year spell as chief sub-editor with the Irish News.
Rankin then spent a year teaching practical newspaper journalism to the first intake of students to the Post-Graduate Diploma in journalism course at the University of Ulster from 1997 to 1998.
He joined the News Letter in July 1998 and was appointed as assistant editor in January 1999.
Rankin became deputy editor in March 2007 and was appointed acting editor in November 2011, before being given the role permanently in September 2012.
Warren Butcher, Johnston Press managing director in Northern Ireland, said: “I want to take this opportunity to thank Rankin for his service and commitment to the News Letter and take time to acknowledge and give praise for the tremendous contribution that he has given to journalism in Northern Ireland over the last 40+ years.
“Rankin is a highly regarded and respected editor in his community and has steered the newspaper through some turbulent political times which is testament to his skill and understanding of the issues.
“He has certainly earned the opportunity to spend more time with his family, and he will be missed by all of his colleagues and on behalf of everyone at the News Letter and across JP Northern Ireland I wish him a long and happy retirement.”
Rankin will remain in post until the autumn and a recruitment process is currently underway to appoint a successor.