Sarawak was a part of the Sultanate of Brunei before it was ceded to British adventurer James Brooke, who ruled it as his personal kingdom from 24 September 1841. The official declaration was not made until 18 August 1842. Brooke took over as a reward for helping to bring about a peaceful settlement facing Bidayuh uprising against the Sultan of Brunei. This marked an onset of three generations of the Brooke family rule.
Kuching became the seat of the Brooke government and underwent remarkable changes. As the administrative capital, it was the focus of attention and development. Some of the first things James Brooke did was to introduce a code of laws and build his residence on a site at the northern bank of the Sarawak River. The present-day Astana (Palace), which is now the official residence of the Governor of Sarawak, is next to the original Brooke building.
Under James Brooke, piracy and headhunting were banned and law and order enforced. However, Kuching remained cramped and lacking in facilities. It was not until 1868 when Charles Brooke became the Second Rajah that greater efforts were made to upgrade the town. Drainage was improved, new buildings and streets sprang up and old wooden shophouses were replaced with brick ones. In fact, most of Kuching from the town centre and its outlying areas was rebuilt after the great fire in 1884.
The Brooke Administration was given the status of Protectorate under Rajah Charles Brooke’s rule and was placed behind the Indian Rajas and Princes. By the end of the Charles Brooke rule, Kuching had grown from a small ramshackle place into a town with attractive Victorian-styled Government buildings and telecommunication service. Sampans (small boats) and trains were the primary mode of transport. There were even sports and entertainment facilities such as a race course and the Sarawak Club, complete with a bar, billiard tables and bowling alleys.
Kuching continued to prosper under Charles Vyner Brooke, who succeeded his father as the Third Rajah of Sarawak. In 1941, Kuching became the venue of the Brooke Government Centenary Celebration. A few months later, the Brooke administration came to a close when the Japanese occupied Sarawak.