Sultan Ahmad Al-Muʽazzam Shah Ibni Al-Marhum Bendahara Sri Maharaja Tun Ali (23 May 1836 – 9 May 1914) was the sixth Raja Bendahara of Pahang and the founder and first modern Sultan of Pahang.[citation needed] Commonly known as Tun Wan Ahmad before his accession, he seized the throne in 1863 after having defeated his elder brother Tun Mutahir in the Pahang Civil War, assuming the title Sri Paduka Dato' Bendahara Siwa Raja Tun Ahmad. In the early years of his reign, Pahang descended into turmoil, with various attempts made by the surviving sons of the late Tun Mutahir, based in Selangor, to overthrow him. This led to Pahang's decisive involvement in the Selangor Civil War that successfully brought it to a conclusive end.