The foreign relations of South Africa have spanned from the country's time as Dominion of the British Empire to its isolationist policies under Apartheid to its position as a responsible international actor taking a key role in Africa, particularly Southern Africa.
South Africa is active in the United Nations, the African Union and the Commonwealth of Nations. Considered a possible permanent addition to the United Nations Security Council, South Africa was elected in 2006 and again in 2010 by the UN General Assembly to serve on the Security Council, which it did until 31 December 2012.
South Africa, as a key member of the British Empire and Commonwealth, fought alongside the United Kingdom and the Allies in both World War I and World War II, and it participated in the postwar UN force in the Korean War. South Africa was a founding member of the League of Nations and in 1927 established a Department of External Affairs with diplomatic missions in the main Western European countries and in the United States.
South Africa introduced apartheid in 1948, as a systematic extension of pre-existing racial discrimination in the country. As a result, the country became increasingly isolated internationally until apartheid was ended and racial equality introduced in 1990–3.