structural:reformatting, structural:scholar_edition
1300–1800

The first fortified settlements on the site of today's Warsaw were located in Bródno (9th/10th century) and Jazdów (12th/13th century). After Jazdów was raided by nearby clans and dukes, a new fortified settlement was established on the site of a small fishing village called "Warszowa". The Prince of Płock, Bolesław II of Masovia, established the modern-day city in about 1300 and the first historical document attesting to the existence of a castellany dates to 1313. With the completion of St John's Cathedral in 1390, Warsaw became one of the seats of the Dukes of Masovia and was officially made capital of the Masovian Duchy in 1413. The economy then predominantly rested on craftsmanship or trade, and the town housed approximately 4,500 people at the time.

During the 15th century, the population migrated and spread beyond the northern city wall into a newly formed self-governing precinct called New Town. The existing older settlement became eventually known as the Old Town. Both possessed their own town charter and independent councils. The aim of establishing a separate district was to accommodate new incomers or "undesirables" who were not permitted to settle in Old Town, particularly Jews. Social and financial disparities between the classes in the two precincts led to a minor revolt in 1525. Following the sudden death of Janusz III and the extinction of the local ducal line, Masovia was incorporated into the Kingdom of Poland in 1526. Bona Sforza, wife of Sigismund I of Poland, was widely accused of poisoning the duke to uphold Polish rule over Warsaw.

In 1529, Warsaw for the first time became the seat of a General Sejm and held that privilege permanently from 1569. The city's rising importance encouraged the construction of a new set of defenses, including the landmark Barbican. Renowned Italian architects were brought to Warsaw to reshape the Royal Castle, the streets and the marketplace, resulting in the Old Town's early Italianate appearance. In 1573, the city gave its name to the Warsaw Confederation which formally established religious freedom in the Polish–Lithuanian Commonwealth. Due to its central location between the capitals of the Commonwealth's two component parts, Poland and Lithuania, which were Kraków and Vilnius respectively, Warsaw became the capital of the Commonwealth and the Polish Crown when Sigismund III Vasa transferred his royal court in 1596. In the subsequent years the town significantly expanded to the south and westwards. Several private independent districts (jurydyka) were the property of aristocrats and the gentry, which they ruled by their own laws. Between 1655 and 1658 the city was besieged and pillaged by the Swedish, Brandenburgian and Transylvanian forces. The conduct of the Great Northern War (1700–1721) also forced Warsaw to pay heavy tributes to the invading armies.

The reign of Augustus II and Augustus III was a time of great development for Warsaw, which turned into an early-capitalist city. The Saxon monarchs employed many German architects, sculptors and engineers, who rebuilt the city in a style similar to Dresden. The year 1727 marked the opening of the Saxon Garden in Warsaw, the first publicly accessible park. The Załuski Library, the first Polish public library and the largest at the time, was founded in 1747. Stanisław II Augustus, who remodelled the interior of the Royal Castle, also made Warsaw a centre of culture and the arts. He extended the Royal Baths Park and ordered the construction or refurbishment of numerous palaces, mansions and richly-decorated tenements. This earned Warsaw the nickname Paris of the North.

Warsaw remained the capital of the Polish–Lithuanian Commonwealth until 1795 when it was annexed by the Kingdom of Prussia in the third and final partition of Poland; it subsequently became the capital of the province of South Prussia. During this time, Louis XVIII of France spent his exile in Warsaw under the pseudonym Comte de Lille.