"#BreakingNews @amlahash today called time on one of the great international careers of the modern era when he announced his retirement from all formats of international cricket. He will continue to be available for domestic cricket as well as the Mzansi Super League. #AmlaRetires," Cricket South Africa tweeted.
Amla played 349 matches across the three formats for the Proteas and scored more than 18,000 runs, including 55 centuries and 88 half-centuries.
Amla remains the only South African cricketer to score a triple century in Test cricket. In 124 Tests, Amla scored 9,282 runs at 46.41 with 28 centuries and 41 fifties.
His ODI career was equally successful as he was ranked among the best batsmen in the format, holding the South African record of 27 ODI tons. He was also the quickest to 2,000, 3,000, 4,000, 5,000, 6,000 and 7,000 ODI runs.
In 181 ODIs, Amla amassed 8,113 runs at 49.46 with 27 hundreds and 39 half-centuries.
"I learnt many lessons during this incredible ride, made many friends and most importantly shared in the love of a brotherhood called #proteafire. I would like to thank my parents for their prayers, love and support, it is their shadow over me that enabled me to play for years under the Protea sun," Amla said in an official statement.
"Also, My family, friends and agent, my teammates and every member of the support staff throughout this incredible journey. A heartfelt thank you to every one of you," he added.
Speaking on the development, CSA Chief Executive Thabang Moroe said: "It is always sad to bid farewell to one of the true legends of the game.
"But at the same time this is rather an occasion to celebrate the richness that Hashim brought to the game around the world both on and off the field. His humility has always been his standout quality and I cannot imagine a better role model to teach us all how to lead better lives. He has added great value, not only to the Proteas but also to the country at large."
( With inputs from IANS )