The written history of Singapore dates back to the third century. Later, the Kingdom of Singapura rose in importance during the 14th century under the rule of Srivijayan prince Parameswara and Singapore became an important port, until it was destroyed by Acehnese raiders in 1613. The modern history of Singapore began in 1819 when Englishman Sir Stamford Raffles established a British port on the island. Under British colonial rule, Singapore grew in importance as a centre for both the India-China trade and the entrepôt trade in Southeast Asia, rapidly becoming a major port city.
During World War II, Singapore was conquered was occupied by the Japanese Empire from 1942 to 1945. When the war ended, Singapore reverted to British control, with increasing levels of self-government being granted, culminating in Singapore's merger with the Federation of Malaya to form Malaysia in 1963. However, social unrest and disputes between Singapore's ruling People's Action Party and Malaysia's Alliance Party resulted in Singapore's separation from Malaysia. Singapore became an independent republic on 9 August 1965.
Facing severe unemployment and a housing crisis, Singapore embarked on a modernization programme beginning in the late 1960s through the 1970s that focused on establishing a manufacturing industry, developing large public housing estates and investing heavily on public education. Since independence, Singapore's economy has grown by an average of nine percent each year.[clarification needed] By the 1990s, the country had become one of the world's most prosperous nations, with a highly developed free market economy, strong international trading links, and the highest per capita gross domestic product in Asia outside of Japan.