The number eight won 95 caps for his country and also represented the British & Irish Lions during a long and successful career.
The Leinster star captained his country on 13 occasions but has been unable to recover from a back injury picked up last year, with two operations failing to correct the issue.
After nearly a year without playing, Heaslip admits it is the right time to call it quits and focus on the next chapter of his life.
He told reporters: "I've had the time of my life on and off the rugby pitch but now it's time for the next chapter.
"My goal when I started my career 14 years ago was to leave the jersey that I wore in a better place and I hope I have done that."