President Cyril Ramaphosa has called for the African continent to continue to unite in the spirit of the founding charter of the African Union.
The President was speaking at the Africa Day celebrations at the Cradle of Humankind on Thursday.
The day is a commemoration of the founding of the Organisation for African Unity (OAU) in 1963.
"We observe Africa Day to remind ourselves of the resilience we possess as Africans, which has taken us from where we have come into the future. We observe Africa Day to celebrate our unity as Africans, and to remind ourselves of the responsibility we all share to bring about an Africa that is peaceful, prosperous and united," he said.
President Ramaphosa highlighted that the founding charter of the OAU still bears relevance to modern day Africa.
"The charter called for the harnessing of the natural and human resources of our continent for the total advancement of Africans. It called for the building of understanding and solidarity between African countries, to build a larger unity "transcending ethnic and national differences".
"It called on African countries to safeguard and consolidate their hard-won independence, respect for sovereignty and territorial integrity, and for resistance against neocolonialism in all its forms," he said.
The President cited the COVID-19 pandemic as a "trauma" for Africa but also as an example of what the continent can achieve when resources are mobilised for the greater good of Africa.
"But this worst health emergency in living memory did not destroy Africa, because Africans came together and acted as one. The African Union developed a continental response and implemented it with urgency across all the regions of the continent.
"Our collective response to the COVID-19 pandemic gave new momentum to the cause of African integration. We learned as Africans that we have the means, the capacity and the political will to develop and implement solutions to Africa's challenges," President Ramaphosa said.
The President spoke out strongly against xenophobia and discrimination in South Africa.
"Even as we South Africans exercise our national pride, this can never be an excuse to turn against other Africans who live in our midst or have sought refuge in our country. Let us find strength in our diversity. Let us forever strive to find the common ground that unites us as Africans, instead of seeking out what divides us.
"In the words of the African Union Anthem: let us unite and celebrate together the victories won, let us defend our liberty and unity, and let us uphold the bonds that frame our destiny," he said.
Turning to conflicts on the continent and abroad, President Ramaphosa once again called for the resolution of conflicts by negotiation and dialogue.
He said the continent is "being dragged into conflicts far beyond our own border".
"Some countries, including our own, are being threatened with penalties for pursuing an independent foreign policy and for adopting a position of non-alignment. As African countries, we have painful memories of a time when proxy wars were waged on the soils of Africa by foreign superpowers.
"We have not forgotten the terrible, brutal legacy of first having our continent carved up and colonised by European countries, only to find ourselves once more pawns on a chessboard during the Cold War.
"We are not going back to that period in history. That is why I will say it again today. South Africa has not been, and will not be, drawn into a contest between global powers. We will maintain our position on the peaceful resolution of conflict wherever those conflicts occur.
"Guided by the lessons of our history, we will continue to resist calls to abandon our independent and non-aligned foreign policy," he said.