According to the manuscript Purwaka Caruban Nagari, in 15th century Cirebon started as a small fishing village named Muara Jati. At that time the port of Muara Jati already attracted foreign traders. The port master at that time is Ki Gedeng Alang-Alang appointed by the king of Galuh kingdom located inland in Kawali, Ciamis. Ki Gedeng Alang-Alang moved the port to Lemahwungkuk, 5 kilometres southward. As the new settlement leader, Ki Gedeng Alang-Alang was bestowed the title "Kuwu Cerbon" (Cerbon village leader).
A prince from Pajajaran, Prince Walangsungsang, convert to Islam, and was appointed as Adipati of Cirebon with the title Cakrabumi. He established the new kingdom of Cirebon and declared independence from Galuh. The establishment of Cirebon sultanate marked the first Islamic rule in Western Java, that grew from modest fishing village of Muara Jati to a busy port of Java northern coast. Cirebon grew as one of the independent sultanates under the leadership of Sunan Gunungjati, in the early 16th century.
The kingdoms of Banten and Mataram fought over Cirebon, which declared its allegiance to Sultan Agung of Mataram. But the later Mataram king ceded the city to the Dutch in the 1677. A treaty in 1705 saw Cirebon become a Dutch protectorate jointly administered by three sultans whose courts rivalled those of Central Java.
During the time of the Dutch "Culture System" a flourishing trade in colonial cash crops attracted many Chinese entrepreneurs and the Chinese influence is still evident in the batik for which Cirebon is famous. Cirebon suffered a famine in 1844, apparently triggered by a combination of drought and the shift from subsistence agriculture to cash crops, particularly indigo and sugarcane