In the 14th and 15th century, Portuguese explorers traveled down the west African Coast, detailing and mapping the coastline and in 1488 they rounded the Cape of Good Hope. The Dutch East India Company established a trading post in Cape Town under the command of Jan van Riebeeck in 1652, European workers who settled at the Cape became known as the Free Burghers and gradually established farms in the Dutch Cape Colony.
Following the Invasion of the Cape Colony around 1800, mass migrations collectively known as the Great Trek occurred. The discoveries of diamonds and gold in the 19th century had a profound effect on the fortunes of the region, introducing a shift away from an exclusively agricultural economy towards industrialization and the development of urban infrastructure.
Following the South African War (1899–1902), the Union of South Africa was created as a self-governing dominion of the British Empire in 1910. The monarchy came to an end in 1961 when the Republic of South Africa was established.
From 1948–1994, South African politics was dominated by Afrikaner nationalism. Racial segregation and white minority rule known officially as apartheid, an Afrikaans word meaning "separateness”, was implemented in 1948.
On 27 April 1994, after decades of armed struggle, terrorism and international opposition to apartheid, the African National Congress (ANC) achieved victory in the country's first democratic election.