South African forces fought on the Allied side in World Wars I and II and participated in the postwar UN force in Korea. 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 west European countries and in the United States. At the founding of the League of Nations, South Africa was given the mandate to govern Southwest Africa, now Namibia, which had been a German colony before World War I. In 1990, Namibia attained independence, with the exception of the enclave of Walvis Bay, which was reintegrated into Namibia in March 1994. After South Africa held its first nonracial election in April 1994, most sanctions imposed by the international community in opposition to the system of apartheid were lifted. On June 1, 1994, South Africa rejoined the Commonwealth, and on June 23, 1994, its credentials to the UN General Assembly were accepted. South Africa also joined the Organization of African Unity (OAU).
Having emerged from the international isolation of the apartheid era, South Africa has become a leading international actor. Its principal foreign policy objective is to develop good relations with all countries, especially its neighbors in SADC and the other members of the OAU. South Africa has played a key role in seeking an end to various conflicts and political crises on the African continent, including in Burundi, the Democratic Republic of Congo, the Comoros, and Zimbabwe. In August 1998, South Africa assumed the chair of the Non-Aligned Movement, which it will relinquish in July 2002.