It remained a western outpost of the Duchy of Greater Poland, established by the 1138 Testament of Bolesław III Krzywousty, after the loss of Lubusz Land in the mid-13th century and was incorporated into the Poznań Voivodeship of the Polish Crown upon the coronation of King Władysław I the Elbow-high in 1320. Under the rule of his successor Casimir III the Great (1333–1370) German settlers began to migrate into the area in the course of the Ostsiedlung. Town privileges were confirmed by King Casimir IV Jagiellon in 1485. Międzyrzecz was a royal town of the Polish Crown and the seat of starosts (local royal administrators). In 1520 it was ravaged by the Germans.