Launch app →

Human verified. Last updated by our editorial team on .

Oceania · The Islamic sultanates

Mataram Sultanate

1587–1755

The Mataram Sultanate was the last great Javanese state before the Dutch: an inland kingdom founded in 1587, which conquered the north coast, besieged Batavia twice, ruled the rice plains of central Java for a century and a half, and ended by being divided — by treaty, in 1755 — into the two courts that still exist as Yogyakarta and Surakarta.

Existed
1587–1755
Shown on the map
1588–1676, 1683–1743 (2 periods)
Peak area
66k km²
Region
Oceania

It is the state in which Java's classical political culture reached its final form: the priyayi bureaucracy, the bupati regents, the shadow theatre and the gamelan, the mystical synthesis of Islam and Javanese cosmology, and the idea of the king as the axis of the cosmos. It is also the state that lost its sovereignty in stages, by treaty after treaty, until the sultan was a landlord under Dutch protection.

At a glance

NameMataram Sultanate; Kasultanan Mataram; later Kartasura and Surakarta
Dates1587–1755 (the site draws 1588–1676 and 1683–1743)
WhereInland central Java: Kotagede, Karta, Plered, Kartasura
FounderSutawijaya (Senapati), installed at Kotagede
Greatest rulerSultan Agung, 1613–1646
ReligionIslam, in a Javanese mystical synthesis
EconomyIrrigated rice, forced deliveries, tolls and the coast's trade
EndTreaty of Giyanti, 13 February 1755: divided into Yogyakarta and Surakarta

What was the Mataram Sultanate?

An inland Javanese kingdom that grew out of the ruins of Demak and Pajang, conquered the north coast, and made itself the dominant power in Java. Its capital moved four times — Kotagede, Karta, Plered, Kartasura — and its history is a long struggle between the king and his own regional lords, with the Dutch East India Company as the third party that both sides used.

Its importance is structural. Mataram fixed the shape of Javanese government: the bupati as a hereditary regent, the priyayi as a service aristocracy, the village as the unit of taxation, and the court as the centre of culture. Modern Java's administrative geography and social hierarchy are Mataram's legacy, and so is the division of the royal house into the two courts of Surakarta and Yogyakarta.

How did it begin?

With a local lord and a vacuum. Sutawijaya, known as Senapati, was the adopted son or vassal of the ruler of Pajang; in the 1580s he made himself independent, defeated Pajang, and established his court at Kotagede, south-east of modern Yogyakarta. The date is fixed materially: the gate of the Kotagede mosque carries the Javanese year 1509, which is 1587

The mosque at Kotagede, whose gate carries the Javanese year 1509 — 1587, and the cepuri — the citadel — is dated 1585–94 by the chronicles and the archaeological service.

The kingdom he founded was small, inland and agricultural. Its expansion began under his son and reached its height under his grandson, Sultan Agung, who turned a central Javanese principality into the dominant power on the island.

Who was Sultan Agung?

The greatest of the Mataram kings, and the one whose reign defined the state. He ruled from 1613 to 1646, conquered the north coast ports in the 1620s, and made Mataram a rice-and-timber empire with a court culture that set the standard for Javanese civilisation. "Sultan Agung" is a posthumous name given by historians; his own titles were different.

His two great projects were the siege of Batavia and the reform of the calendar. The first failed; the second succeeded so completely that the Javanese year he introduced is still used for ritual purposes. He also gave Mataram its ideology: the king as the khalifatullah, God's deputy, and the court as the centre of a cosmos whose order depended on his ritual purity.

Anyakrakusuma, a Mataram ruler, in a later portrait
Anyakrakusuma of Mataram. Public domain, via Wikimedia CommonsPublic domain, via Wikimedia Commons

Why did Batavia survive?

Because the Dutch had sea power and Mataram had none. Agung besieged Batavia in 1628 and again in 1629, with armies of tens of thousands; both campaigns failed. The second was destroyed less by Dutch firepower than by hunger: the Javanese had depended on rice magazines at Tegal, and the Dutch — or, in some accounts, the retreating Javanese themselves — burned them, so that the army starved on the march.

The failure mattered for two centuries. Mataram could not take a fortified coastal city, and the Dutch could not conquer the interior; the two powers settled into a relationship of mutual need and mutual suspicion, which the Company exploited by treaty and the kings by playing for time.

What was the calendar reform?

A change of era, not of faith. In 1633 Agung replaced the Śaka era, which was solar-lunar and Indian in origin, with a new Javanese era — Ajumgi or Anno Javanico — counted in lunar years from A.J. 1555. The reform aligned the court calendar with the Islamic lunar year while keeping Javanese ritual time, and it is the clearest example of Mataram's cultural programme: Islam and Javanese tradition fused under royal authority.

The calendar is also a dating tool. Many Javanese charters and chronicles use A.J., and converting them requires care, because the year is lunar and the start date falls in different Gregorian years depending on the source.

## What was the court like?

The centre of the Javanese world. The court was a ritual institution as much as a government: the king's person was the axis of the cosmos, his purity guaranteed the harvest, and his ceremonies — the garebeg, the sekaten, the rajah suwala — marked the turning of the year. The gamelan, the shadow theatre, the dance and the batik of the court set the standards that the regions copied.

Around the king stood the priyayi: officials and nobles who held land and title in return for service, and whose culture — refined speech, etiquette, mysticism, poetry — became the model of Javanese gentility. It was a small elite ruling a large peasant population through ritual prestige and rice, and its values survived the loss of its sovereignty.

How was it governed?

Through regents and a service aristocracy. The kingdom was divided into bupati jurisdictions, each under a regent who raised taxes, labour and troops; above them, the priyayi — the court nobility and officials — staffed the central administration, and the king ruled with a council and a body of religious officials. Below all of it, the village paid rice and labour.

This was a state that governed through people rather than institutions. Its revenue was rice, delivered in kind; its army was levies raised by the regents; its administration was the personal service of officials who held land and title in return. That made it cheap and flexible, and it made it fragile: the regents were also the men who revolted.

## What did the court produce?

A literature and a historical tradition. The Babad Tanah Jawi — the chronicle of Java — was compiled and recopied at the Mataram courts from the seventeenth century, and it is the source through which the whole Javanese past, from Adam to the sultans, is narrated. The court poets produced serat — verse chronicles, romances and mystical treatises — in great quantity, and the wayang repertoire was fixed in the form still performed.

The court also produced a political theology. The king was khalifatullah, God's deputy, and the wahyu — the divine radiance — was thought to pass to the ruler who possessed the legitimate claim; the Babad narrates Javanese history as the transfer of that radiance from kingdom to kingdom. It is a way of writing history that makes conquest into proof of legitimacy, and it is the reason the chronicles must be read against the inscriptions.

What happened after Agung?

A long decline, punctuated by wars. Agung died in early February 1646 — not 1645, which is the Javanese year — and his son made peace with the Company in 1646, the first of the treaties that would define the relationship. The next decades saw court intrigues, revolts and the rise of new powers on the coast and in Madura.

The decisive crisis came in the 1670s. A Central Javanese crop failure in 1674–76 was followed by the Trunajaya war (1674–79), a rebellion led by a Madurese prince that overran much of the kingdom and forced the court to flee. The Dutch intervened on the king's side, and the price was the treaty of 1677.

## What was the interior economy?

Rice, and the labour to grow it. Central Java's volcanic soils and monsoon rains supported dense populations, and Mataram's revenue came from taxing the harvest in kind; the regents collected it, the villages delivered it, and the court consumed and redistributed it. There was little money in the interior economy, and what there was came from the coast.

The Dutch changed that gradually. The rice deliveries fixed in the treaties of 1677, 1705 and 1746 turned the kingdom into a supplier for Batavia, and the quotas — five thousand coyang a year at ten rixdollars by 1746 — were paid in a currency the Javanese did not control. That is how a rice kingdom became a dependent economy without being conquered.

What did the 1677 treaty do?

It made the Company a party to Javanese politics. The Speelman contract of 1677 — signed in February and revised in October — imposed a frontier at the Karawang river, exempted Company goods from tolls, allowed factories anywhere in the kingdom, set a rice quota for Batavia and permitted a VOC garrison. It did not divide the kingdom; that came later, and the common claim that 1677 "split" Mataram is wrong.

Further treaties followed: the Semarang grant of 1678, the boundary and monopoly settlement of 1705 (opium and textiles), and the treaty of 1743, which ceded Madura and the Eastern Salient, granted a coastal strip, and — most tellingly — placed two hundred regents under Company protection against their own king.

## What happened to the coast?

It was conquered, taxed and lost. Sultan Agung took the north coast ports in the 1620s and ended their independence, but Mataram had no navy and no merchant marine, and the coast's trade was run by Chinese, Malay and Gujarati merchants under Dutch pressure. The ports that had made Demak rich became the kingdom's tax farms.

The consequence was a shift of gravity to the interior that lasted two centuries. Java's court culture, its literature and its politics became inland and agrarian, while the maritime economy passed to the Dutch and to the Chinese merchants who worked with them. Modern Java's division between a courtly interior and a commercial coast begins here.

What was the Chinese war?

The last great Javanese war against the Dutch, in 1740–43. After the Company massacred the Chinese community of Batavia in 1740, Javanese forces joined the Chinese insurgents and besieged Semarang; the king, Pakubuwana II, fled his capital on 30 June 1742 and was restored by the Dutch. The war ended with the treaty of 1743, which completed Mataram's reduction to a protected state.

The settlement of 1746 fixed the rice deliveries — five thousand coyang a year at ten rixdollars, split between the Company and the crown — and turned the kingdom's economy into an instrument of Dutch provisioning. Mataram was now a supplier, not a rival.

## How did the Dutch win?

By being indispensable. The Company never conquered Mataram; it made itself the guarantor of whichever claimant won, and charged territory, trade rights and rice for the service. Each treaty was signed by a king who needed Dutch troops against his own relatives, and each one transferred a little more sovereignty.

That is the pattern of Javanese political history after 1677: civil war, Dutch mediation, territorial cession, and a court that survived with less power and more ceremony. By 1755 the king was a landlord under Company protection, and the "sultanate" was an institution of ritual and culture rather than a state.

How did the division happen?

By treaty, in 1755, after a succession war. The Javanese crisis of 1741–43 had left the court divided between Pakubuwana II and his nephew Mangkubumi, and the Company, having backed the king, negotiated with the rebel. The Treaty of Giyanti, signed on 13 February 1755, divided the kingdom: Mangkubumi became Sultan Hamengkubuwana I in Yogyakarta, Pakubuwana III kept Surakarta, and each received 53,100 households.

The treaty's language is revealing: the Company granted the territories as a fief, not as a recognition of sovereignty, and the price list attached to it fixed the value of rice at 8.25 guilders a coyang. By 1812, further divisions had produced four courts. The Mataram Sultanate ended not in battle but in a notarial act.

## How is it remembered?

As the last independent Javanese state, and as the golden age of Javanese court culture. The two successor courts, Yogyakarta and Surakarta, preserve its ceremonies, its gamelan, its dance and its titles; the sultan of Yogyakarta is the governor of a special region, and the susuhunan of Surakarta still keeps a court. Indonesian national history treats Mataram as the culmination of the pre-colonial Javanese state.

The record is more sober. Mataram failed to take Batavia, lost its coast, ceded its territory by treaty, and ended as a protected fiefdom. Its endurance was cultural rather than political: the courtly values it created outlived the state that created them, and that is a kind of survival the treaties could not take away.

Common myths about Mataram

MythWhat the evidence says
Sultan Agung made peace with the Dutch in 16411641 is the Meccan grant of the title sultan; the peace treaty is 1646, under his son.
Agung died in 1645He died in early February 1646; 1645 is the Javanese year.
The 1677 treaty divided MataramIt imposed a frontier, toll exemptions, factories, a rice quota and a garrison; the division came in 1755.
Mataram fell in 1755It was divided by treaty; the courts continued, and the sultan became a protected ruler.
The 1633 reform converted Java to IslamIt changed the calendar era, not the religion.
The 1629 siege failed because of Dutch firepower aloneThe army starved after the rice magazines at Tegal were destroyed.
The kingdom was a centralised stateIt governed through regents and a service aristocracy, who were also its rebels.
Yogyakarta and Surakarta are ancient rivalsThey are the two halves created by the treaty of Giyanti in 1755.

Timeline of Mataram

YearEvent
1587Kotagede mosque gate dated A.J. 1509
1613Sultan Agung accedes
1620sConquest of the north coast
1628First siege of Batavia
1629Second siege; the army starves
1633Calendar reform (A.J. 1555)
1641Meccan grant of the title sultan
1646Agung dies; peace treaty signed
1674–76Central Javanese crop failure
1674–79Trunajaya war
1677Speelman contract
1705Boundary and monopoly treaty
1740–43Chinese war; Pakubuwana II flees, 30 June 1742
1743Treaty ceding Madura and the Eastern Salient
1746Rice delivery settlement
13 February 1755Treaty of Giyanti; the kingdom divides

What the map shows next

At 1632 on the map Mataram is at its height, and the Dutch East Indies holds only Batavia and a few ports.

At 1755 on the map the kingdom divides, and Yogyakarta and Surakarta begin.

Common questions

What was the Mataram Sultanate?
The last great Javanese kingdom before Dutch rule, founded in 1587, conqueror of the north coast, and divided by treaty in 1755.
Who founded it?
Sutawijaya, known as Senapati, who established his court at Kotagede in the 1580s.
Who was Sultan Agung?
The greatest Mataram king (1613–1646), who conquered the coast, besieged Batavia twice and reformed the calendar.
Did Mataram defeat the Dutch?
No. It besieged Batavia in 1628 and 1629 and failed both times, largely through supply failure.
What was the 1633 reform?
The introduction of the Javanese lunar era (A.J. 1555) in place of the Śaka era.
When did the Dutch become dominant?
Through the treaties of 1677, 1705 and 1743, each of which extended Company control over trade, territory and the regents.
What was the Treaty of Giyanti?
The 1755 treaty that divided Mataram into Yogyakarta and Surakarta.
Why did the kingdom divide?
Because the succession war of the 1740s left two claimants, and the Company negotiated with both.
Is Yogyakarta still a sultanate?
Yes: it is a special region of Indonesia whose governor is the sultan, an arrangement dating from 1950.
What is Mataram's legacy?
The Javanese administrative system, the priyayi and bupati, the court culture, and the division of the royal house.

Sources

Every source below was consulted while writing this entry.

Every source below was consulted while writing this entry.

Primary and official sources

  1. The Kotagede mosque inscription, A.J. 1509.
  2. The Babad Tanah Jawi and the Babad Momana.
  3. The Speelman contract of 1677, in the Corpus Diplomaticum Neerlando-Indicum.
  4. The treaties of 1678, 1705, 1743 and 1746, in the same corpus.
  5. The Treaty of Giyanti, 13 February 1755.
  6. BPCB Yogyakarta, on Kotagede.

Scholarship and reference works

  1. de Graaf, De regering van Sultan Agung (1958) and De regering van Sunan Mangkurat I.
  2. de Graaf and Pigeaud, on the Javanese chronicles.
  3. Ricklefs, Jogjakarta under Sultan Mangkubumi, Mystic Synthesis and A History of Modern Indonesia.
  4. Nagtegaal, on the Dutch–Javanese relationship.
  5. Carey, on the 1740s crisis.
  6. Remmelink, on the Chinese war.
  7. Sutherland, "The Priyayi".

Data sources for the map

  1. Cliopatria v0.12 (Seshat Global History Databank, CC BY 4.0).
  2. Historical Basemaps (GPL-3.0).

This entry was written from the sources above and last updated .

Text available under CC BY-SA 4.0: reuse it with a credit to The World Through Time and a link to this page.

Border geometry for the map itself comes from Cliopatria v0.12 (Seshat Global History Databank, CC-BY-4.0).

History in your inbox, once a week

A weekly email with new articles and glossary entries. Unsubscribe anytime. Privacy policy.

See the Mataram Sultanate in its world

Open the atlas at 1632 and every neighbour, rival and successor is on screen with it — then drag the slider and watch what happens next.

Open the map at 1632 →