Sandakan (, Jawi: , ) formerly known at various times as Elopura, is the capital of the Sandakan District in Sabah, Malaysia. It is the second largest city in Sabah after Kota Kinabalu. It is located on the Sandakan Peninsula and east coast of the state in the administrative centre of Sandakan Division and was the former capital of British North Borneo. In 2010, the city had an estimated population of 157,330 while the overall municipal area had a total population of 396,290. The population of the municipal area had increased to 439,050 by the 2020 Census. Before the founding of Sandakan, Sulu Archipelago was the source of dispute between Spain and the Sultanate of Sulu for economic dominance in the region. By 1864, Spain had blockaded the Sultanate possessions in the Sulu Archipelago. The Sultanate of Sulu awarded a German consular service ex-member a piece of land in the Sandakan Bay to seek protection from Germany. In 1878, the Sultanate sold north-eastern Borneo to an Austro-Hungarian consul who later left the territory to a British colonial merchant. The German presence over the area raised concern among the British. As a result, a protocol was signed between the British, German and the Spanish to recognise Spanish sovereignty over the Sulu Archipelago, in return for the Spanish not intervening in British affairs in northern Borneo. Sandakan began to prosper when the British North Borneo Company (BNBC) started to build a new settlement in 1879, developing it into an active commercial and trading centre as well as making it the main administrative centre for North Borneo. The British also encouraged the migration of the Chinese from British Hong Kong to develop the economy of Sandakan. However, the prosperity halted when the Japanese occupied the area. As the war continued and Allied bombing started in 1944, the town was totally destroyed. Unable to fund the costs of the reconstruction, the administrative powers of North Borneo were handed over to the Crown Colony government. Subsequently, the administrative capital of North Borneo was moved to Jesselton. As part of the 1948–1955 Colonial Office Reconstruction and Development Plan, the crown colony government began to develop the fishing industry in Sandakan. Sandakan is one of the main ports for oil, tobacco, coffee, sago, and timber exports. Other economic activities include fishing, ship building, eco-tourism, and manufacturing. Among the tourist attractions in Sandakan are Sandakan Heritage Museum, Sandakan