The Jaffna Kingdom (1215–1624 CE), also known as Kingdom of Aryacakravarti, of modern northern Sri Lanka was a historic monarchy that came into existence around the town of Jaffna on the Jaffna peninsula traditionally thought to be established after the invasion of Magha, who is credited with the founding of the Jaffna kingdom and is said to have been from Kalinga, in India. Established as a powerful force in the north, northeast and west of the island, it eventually became a tribute paying feudatory of the Pandyan Empire in modern South India in 1258, gaining independence in 1323, when the last Pandyan ruler of Madurai was defeated and expelled in 1323 by Malik Kafur, the army general of the Muslim Delhi Sultanate. For a brief period, in the early to mid-14th century, it was an ascendant power in the island of Sri Lanka when all regional kingdoms accepted subordination. However, the kingdom was eventually overpowered by the rival Kotte Kingdom, around 1450 when it was invaded by Prince Sapumal under the Kotte Kingdom’s directive.
It was freed of Kotte control in 1467; its subsequent rulers directed their energies towards consolidating its economic potential by maximizing revenue from pearls and elephant exports and land revenue. It was less feudal than most of the other regional kingdoms on the island of Sri Lanka of the same period. During this period, important local Tamil literature was produced and Hindu temples were built, including an academy for language advancement.
The arrival of the Portuguese on the island of Sri Lanka in 1505, and its strategic location in the Palk Strait connecting all interior Sinhalese kingdoms to South India, created political problems. Many of its kings confronted and ultimately made peace with the Portuguese. In 1617, Cankili II, a usurper to the throne, confronted the Portuguese but was defeated, thus bringing the kingdom’s independent existence to an end in 1619. Although rebels like Migapulle Arachchi–with the help of the Thanjavur Nayakkingdom–tried to recover the kingdom, they were eventually defeated. Nallur, a suburb of modern Jaffna town, served as its capital.