At the end of his life, John III had a succession problem: his three sons John, Henry and Godfrey had all predeceased him, thus leaving only his three daughters:
According to the Holy Roman Empire's official feudal law, only men were allowed to rule, and be successors to previous rulers. Since the 13th century, however, when a deceased ruler lacked male descendants, Holy Roman Emperors and Kings of the Romans had often enfeoffed one of his daughters instead of different male relatives or male in-laws, thus introducing cognatic succession. However, in many lands throughout the Holy Roman Empire this new phenomenon was resisted in favour of traditional agnatic succession. Moreover, every case of female inheritance still required approval of the feudal overlord by special request; it did not mean every subsequent case would be accepted. In 1204, Philip of Swabia granted Henry I, Duke of Brabant the ius Brabantinum: the right of a woman to become ruler of the duchy if male heirs were lacking. The cognatic principle of hereditary succession to or via female descendants had been applied several times in Brabant ever since, and it had also been applied in the neighbouring counties of Holland, Zealand and Hainaut, amongst others. In 1354, John III determined that Joanna would inherit all his territories and that Margaret and Mary would be financially compensated. Although John III was not the first Brabantian duke to appoint his daughter as his successor under the ius Brabantinum, still not all parties in mid-14th-century Brabant agreed with this practice. When John died on 5 December 1355, his oldest daughter succeeded him in Brabant and the Duchy of Limburg according to his plan. However, this inheritance settlement was challenged by his sons-in-law in Guelders and Flanders, who demanded a susterdeylinghe, meaning a territorial partition between the three sisters and thus between Luxemburg, Flanders and Guelders. Before John's death, Louis of Male had tried and failed to gain control over the Lordship of Mechelen, but now sensed a new opportunity to gain even more.
War
On 15 June 1356, Louis of Flanders declared war on Brabant. The Flemish armies were initially extremely successful. Brussels was besieged and captured. By the end of August 1356, Mechelen, Leuven, Vilvoorde, Antwerp, Grimbergen, Tienen and Nivelles had surrendered to the Flemish. Joanna took refuge in Binche, and later 's-Hertogenbosch. Meanwhile, Reginald III, Duke of Guelders and married to John's third daughter Mary of Brabant, also disputed the succession and made war on Brabant. In 1356, he agreed to recognise Joanna as duchess in exchange for the acquisition of the Lordship of Turnhout and a substantial annual payment from Brabant. Wenceslaus I, Duke of Luxembourg, husband of Joanna, requested help for Brabant from his brother, Charles IV, Holy Roman Emperor. This was granted in October 1356. On learning of this, a coup d'état took place in Brussels and the Flemish were pushed out. Similar reverses took place in other Brabantian towns. A peace was signed at Ath on 4 June 1357, brokered by William III, Count of Hainaut. It made concessions to Flanders.