The 32-year-old scored 29 goals in 68 games with the Panthers, making him the all-time best scorer in the country.
The Gabonese Football Federation (Fegafoot) confirmed that Aubameyang had written to inform them of his decision.
“After 13 years of proudly representing my country, I regret to inform you that my international career has come to an end,” the former Arsenal player tweeted.
“I’d want to express my gratitude to the Gabonese people and all those who have supported me in both good and difficult times.
“I’ll never forget the day I made my debut or the day I received the African Player of the Year title after returning from Nigeria.” It’s an unforgettable experience to share it with everyone.
“I want to thank my father for inspiring me to strive to be like him, and I hope that by wearing our colors, I have made him proud.”
Fegafoot responded by praising his “enormous career” as a footballer “who knew how to promote Gabon’s image around the world through his professionalism.”
The Fegafoot statement said, “Pierre-Emerick Aubameyang will always be an example for future generations.”
“In the future, the big football family will be able to rely on his knowledge.”
Aubameyang was born in France and played for the French under-21 team before switching to Gabon to follow in his father’s footsteps, who captained the team at their first Nations Cup finals appearance in 1994.
He didn’t always get along with Fegafoot, like he did in 2018, when he chastised the governing body for naming his father as the next national team coach before a contract had been signed.
Aubameyang scored in his international debut, a 2-1 triumph in Morocco in 2009, and has appeared in four Africa Cup of Nations finals.
The striker was in Gabon’s squad for the postponed 2021 Nations Cup this year, but he missed all of their games in Cameroon after getting Covid-19 and subsequently suffering from ‘heart lesions,’ according to reports.
The Panthers begin their qualifying campaign for the 2023 tournament on 4 June in Ivory Coast, where they will face DR Congo, before hosting Mauritania four days later.