History of Java Island - The Javanese are mostly descended from migrants who settled the island in waves from about 4000 BC. Sawah - or wet rice - agriculture was developed gradually from 2000 BC, and trade with South India began as early as the 3rd century AD. It's believed that this contact led to the adoption of Hinduism in coastal kingdoms, while Southeast Asian Buddhism was also an influence and developed side by side with Hinduism, along with older beliefs.
In 732 AD the Hindu King Sanjaya founded the kingdom of Mataram, Java's
first major political entity, which controlled much of central Java and
built the Borobudur temple complex. By the 10th century, King Sendok's
East Javanese kingdom was dominant; it was later extended by Airlangga
and split into two, the eastern Janggara and the western Kediri, after
Mongols invaded Java in 1292, bringing to the throne a new king,
Wijaya, and a new kingdom, the Majapahit Empire, which would become the
most powerful and famous of Javanese kingdoms until it fell in 1400. By
which time Islam was making serious inroads, especially in coastal
ports. Coinciding with Islam's rise was the arrival of the Portuguese in
1511, soon followed by the Spanish, British and Dutch.
In the course of the 17th century, the Dutch became increasingly
militaristic and played their rivals off one another. By the early 19th
century the Dutch had extended their influence over the sultanates of
the interior and claimed Java as Dutch territory.
During the Second World War, in 1942, the island came under the control
of Japanese. When the Japanese left the island in 1945, Sukarno
proclaimed independence but the Dutch returned and an armed struggle
ensued. Ultimately, Indonesia achieved independence in 1949.