It was taken over by the British North Borneo Company in 1881, and became a protectorate of the British Empire with internal affairs still administered by the company in 1888. In 1946 the Company's rule ended and it became the colony of British North Borneo until it was admitted into the Malaysian federation in 1963.
The Philippines claims the whole of Sabah as part of the country's territory. This claim is legally based upon a gift bestowed by the Sultanate of Brunei to the Sultanate of Sulu in 1704, because of military assitance given by the latter to the former. The Sultanate of Sulu then granted to the Philippine Government the title of sovereignty to the territory in 1962.