Siamese invasion of Kedah

The Siamese invasion of Kedah was a military operation mounted by the Kingdom of Siam against the Sultanate of Kedah in November 1821, in the area of what is now northern Peninsular Malaysia.

Background
The Sultanate of Kedah had been a tributary state to Siam during the Ayutthaya period, though the extent of Siamese influence over the northern Malay sultanates varied over time. After the Fall of Ayutthaya in 1767, the northern Malay sultanates were temporarily freed from Siamese domination. In 1786, Francis Light managed to obtain a lease of Penang Island from Sultan Abdullah Mukarram Shah of Kedah on behalf of British East India Company in exchange for British military support against the Siamese or Burmese. In the same year, Siam re-exerted control over the northern Malay sultanates and sacked Pattani. Francis Light, however, failed to secure British military assistance against Siam and Kedah came under Siamese suzerainty. The bunga mas was sent triennially to the Bangkok court.

During the Burmese Invasion of Phuket in 1809, Sultan Ahmad Tajuddin Halim Shah II, who was known in Thai sources as "Tuanku Pangeran" (ตวนกูปะแงหรัน), contributed a sizable force from Kedah to aid the Siamese against the Burmese. In 1813, King Rama II commanded Sultan Ahmad Tajuddin to bring the Sultanate of Perak under Siamese control. Sultan Ahmad Tajuddin then sent forces to capture and occupy Perak on behalf of Siam in 1818. This earned Sultan Ahmad Tajuddin favor of the Siamese king, who raised the Sultan to the rank of Chao Phraya – which was superior to Nakhon Noi the governor of Ligor or Nakhon Si Thammarat who held the rank of Phraya. In 1811, Sultan Ahmad Tajuddin came into conflict with his brother Tunku Bisnu. Tunku Bisnu approached Phraya Nakhon Noi of Ligor and sought Siamese support. Tunku Bisnu was then made the ruler of Setul.

In 1820, King Bagyidaw of Burma planned another invasion of Siam, in which the Kedah Sultanate would inevitably become involved. Tunku Mom, a younger brother of the Sultan, informed Phraya Nakhon Noi that the Sultan of Kedah was forming an alliance with the Burmese against Siam. Lim Hoi, a Phuket-based Chinese merchant caught a Burmese ship bearing a Burmese letter to the Sultan Ahmad Tajuddin. Phraya Nakhon Noi then relayed the information to the Bangkok court. Rama II ordered the Sultan of Kedah to go to Bangkok to explain. The Sultan however, did not go and ceased sending the bunga mas. Rama II then ordered Phraya Nakhon Noi of Ligor to invade the Kedah Sultanate in 1821.

Campaigns
The Siamese were still unsure about the intentions of the Sultan and Kedah had not been aware of Siamese invasion. Phraya Nakhon Noi had already organized a fleet of 7,000 men at Trang and Satun in his preparations against the speculated Burmese invasions. Pretending to launch attack on Mergui and Tenasserim Coast, Phraya Nakhon Noi requested the Sultan of Kedah for provisions. When the Kedahan did not arrive to provide supplies, Nakhon Noi headed his fleet towards Alor Setar in November 1821.

When Nakhon Noi arrived at Alor Setar, the Kedahan were still unaware that the Siamese intention to invade. Paduka Maharaja Sura the Bendahara ceremoniously received the Siamese entourage. Once in the fort, Nakhon Noi ordered his men to attack. Paduka Maharaja Sura was captured and Paduka Seri Raja the Laksamana was killed in battle. Sultan Ahmad Tajuddin managed to flee the city and took refuge on Penang Island, then under British control. Villages were torched and homes were looted. A great number of Malays also fled to Penang and Province Wellesley.

Aftermath
After taking the city, Phraya Nakhon Noi established the Siamese administration over the Kedah State and made his son Phra Pakdiborrirak the Siamese governor of Kedah. Siam imposed the direct rule through Ligor and installed Siamese personnel in Kedah, thus the sultanate ceased to exist for a time. For his victory over Kedah, Rama II raised Nakhon Noi to the rank of Chao Phraya and granted his son Phra Pakdiborrirak the title of Phraya Abhaydhibetr. Phraya Abhaydhibetr would govern Kedah on behalf of his father the governor of Ligor for seventeen years from 1821 until 1838.

By 1822 there was a rise in the population of the British territories caused by an influx of Malays displaced by the invasion. The Siamese presence in Kedah threatened British holdings in Penang, who speculated the Siamese invasion of the island. This prompted Marquess of Hastings, the Governor-General of India, to send John Crawfurd to Bangkok, leading to the first contact between Siam and the British Empire in the Rattanakosin period. Crawfurd arrived in Bangkok in April 1822, he presented the personal letter of Sultan Ahmad Tajuddin to King Rama II blaming Nakhon Noi "the Raja of Ligor" for the incidents. The agreements were not reached as Siam asserted its authoritiy over Kedah and the Sultan. Three years later in 1825, Chao Phraya Nakhon Noi prepared a fleet to invade and conquer the sultanates of Perak and Selangor. Robert Fullerton warned the Raja of Ligor that the Siamese invasion of the sultanates would violate the Anglo-Dutch Treaty of 1824 but went unheeded. Fullerton then sent gunboats to impose a blockade of the Trang River in the modern Trang province where the brigantine fleet of Nakhon Noi was being dispatched and the Siamese expedition was called off.

The Burney Treaty was concluded between Siam and British Empire on 26 June 1826. The Burney Treaty allowed the Siamese view of their rights to prevail. The British government accepted Siamese influence over Kedah in exchange for free trade on stocks and provisions between Siam and Prince of Wales Island and Siam relinquishing its claims over Selangor. The British also agreed to move Sultan Ahmad Tajuddin to somewhere else. Article XIII of the treaty stated that: "The English engage that they will make arrangements for the former Governor of Queda to go and live in some other Country, and not at Prince of Wales' Island or Prye, or in Perak, Salengore, or any Burmese Country." The former Sultan of Kedah was then forcibly moved to Malacca. However, Penang continued to be the center of resistance to Siamese rule.

Tengku Kudin, a nephew of Sultan Ahmad Tajuddin, captured Alor Setar from the Siamese in 1831, though Chao Phraya Nakhon Noi retook Alor Setar four months later. Another act of Kedahan resistance came in 1838 when a nephew of Sultan Admah Tajuddin, Tengku Muhammad Said assembled a fleet at the Merbok River where they fought and won against a Siamese fleet. The fort in Kedah was captured by the Kedahans and the Siamese who were stationed there were massacred. Afterwards, the force of 10,000 Malay men captured Perlis and Trang sacking villages and Buddhist temples. One group reached the Pattani River and invested Songkhla for three months but were driven back to Kedah by the 2,000 Siamese along with their 500 Chinese allies. Later, the Chao Phraya Nakhon Noi entered and conquered Kedah with 1,500 men, at the same time Britain blockaded the coast off Kedah.

Only after the death of Chao Phraya Nakhon Noi in 1838 was a native Malay rule restored. Tunku Anom was made the governor of Kedah in 1838 until Sultan Ahmad Tajuddin pledged for himself to be restored. The Sultan Ahmad Tajuddin, after 20 years of exile, was eventually restored to the Kedah Sultanate in 1842 under Siamese suzerainty.