The Kingdoms of England and Scotland were unified in 1707 creating the Kingdom of Great Britain. Following an attempted republican revolution in Ireland in 1798, the Kingdoms of Ireland and Great Britain were unified in 1801, creating the United Kingdom. The Isle of Man and the Channel Islands remaining outside of the United Kingdom but with their ultimate good governance being the responsibility of the British Crown (effectively the British government). Although, the colonies of North American that would become the United States of America were lost by the start of the 19th century, the British Empire expanded rapidly elsewhere. A century later it would cover one third of the globe. Poverty in the United Kingdom remained desperate however and industrialisation in England led to terrible condition for the working class. Mass migrations following the Irish Famine and Highland Clearances resulted in the distribution of the islands' population and culture throughout the world and a rapid de-population of Ireland in the second-half of the 19th century. Most of Ireland seceded from the United Kingdom after the Irish War of Independence and the subsequent Anglo-Irish Treaty (1919–1922), with the six counties that formed Northern Ireland remaining as an autonomous region of the UK.