Peninsular Malaysia shares a land and maritime border with Thailand in the north and maritime borders with Singapore in the south, Vietnam in the northeast, and Indonesia in the west. East Malaysia shares land and maritime borders with Brunei and Indonesia and a maritime border with the Philippines and Vietnam. Kuala Lumpur is the national capital and largest city while Putrajaya is the seat of federal government. With a population of over 30 million, Malaysia is the world's 44th most populous country. The southernmost point of continental Eurasia, Tanjung Piai, is in Malaysia. In the tropics, Malaysia is one of 17 megadiverse countries, with large numbers of endemic species.
Malaysia has its origins in the Malay kingdoms which, from the 18th century, became subject to the British Empire when the Straits Settlements became British protectorates. Peninsular Malaysia was unified as the Malayan Union in 1946. Malaya was restructured as the Federation of Malaya in 1948, and achieved independence on 31 August 1957. Malaya united with North Borneo, Sarawak, and Singapore on 16 September 1963 to become Malaysia. In 1965, Singapore was expelled from the federation.The country is multi-ethnic and multi-cultural, which plays a large role in its politics. About half the population is ethnically Malay, with large minorities of Malaysian Chinese (the second largest community of Overseas Chinese in the world), Malaysian Indians, and indigenous peoples. The constitution grants freedom of religion but recognises Islam as the established religion of the state. The government system is closely modelled on the Westminster parliamentary system and the legal system is based on common law. The head of state is the king, known as the Yang di-Pertuan Agong. He is an elected monarch chosen from the hereditary rulers of the nine Malay states every five years. The head of government is the Prime Minister. The country's official language is Bahasa Melayu, commonly known as the Malay language. English remains an active second language. In 2017, English proficiency in Malaysia was ranked the 2nd best in Asia (after Singapore) and the 13th best in the world.
A member of the Commonwealth of Nations, Malaysia has had one of the best economic records in Asia since its independence from the United Kingdom with its GDP growing at an average of 6.5% per annum for almost 50 years. The economy has traditionally been fuelled by its natural resources, but is expanding in the sectors of science, tourism, commerce and medical tourism. It is also one of the few developing countries to heavily subsidise education and healthcare. Malaysian citizens are entitled to free public education up to secondary level and public tertiary education fees are subsidised by up to 90%.Basic healthcare services at government-run clinics with prescription cost RM1.Disabled persons, senior citizens and public school students are entitled to free healthcare. Malaysian healthcare services have been described as among the best in the world, and the UN Development Program called the Malaysian healthcare system "a model to other developing countries".
Malaysia's recent rapid development has attracted millions of migrant workers from across Asia. The majority of these migrants are undocumented, a situation which the Malaysian government is struggling to combat, with its treatment and crackdown on migrant workers often criticised by international human rights watchdogs.Malaysia has a newly industrialised market economy, ranked 4th largest in Southeast Asia and 38th largest in the world. With a GDP per capita of $10,430 and an HDI of 0.802, Malaysia is classified as an emerging economy by the World Bank. The International Monetary Fund (IMF) also classifies Malaysia as an emerging and developing country. Malaysia is a founding member of the Association of Southeast Asian Nations, the East Asia Summit, and the Organisation of Islamic Cooperation and a member of the Asia-Pacific Economic Cooperation, the Commonwealth of Nations, and the Non-Aligned Movement. In 2017, Malaysian citizens had visa-free or visa-on-arrival access to 164 countries and territories, ranking the Malaysian passport the 20th most accepted in the world.