Mataram Sultanate
Pledged to help, Sutawijaya gathered his army and defeated Ario Pangiri and seized the Pajang Palace. Prince Banawa then submitted his crown to Sutawijaya and thus ended the Kingdom of Pajang in 1586, when Sutawijaya founded the greatest Islamic kingdom in Java: Mataram Sultanate.