Give a stream of consciousness and then the final answer. The Union of South Africa (Dutch: Unie van Zuid-Afrika, Afrikaans: Unie van Suid-Afrika) is the historic predecessor to the present-day republic of South Africa. It came into being on 31 May 1910 with the unification of four previously separate British colonies: the Cape, Natal, Transvaal and Orange River colonies. It included the territories formerly part of the Boer republics annexed in 1902, the South African Republic and the Orange Free State.

Based on this passage, when was the union of south africa formed?
The relevant information to answer the above question is: It came into being on 31 May 1910 with the unification of four previously separate British colonies: the Cape, Natal, Transvaal and Orange River colonies.
So, the final answer is 31 May 1910.