Malaysian nationality law details the conditions by which a person is a national of Malaysia. The primary law governing nationality requirements is the Constitution of Malaysia, which came into force on 27 August 1957. Malaysia is composed of several former British colonies and protectorates acquired in the 18th and 19th centuries whose residents were British subjects and British protected persons. After federation of its western states in 1948, the country became independent in 1957.