Ottoman period
The Ottomans stayed in Skopje for over 520 years and the city's economic life greatly benefited from its position in the middle of Rumelia, the European province of the Ottomans. The Stone Bridge, "one of the most imposing stone bridges to be found in Yugoslavia", was built under the patronage of Sultan Mehmed II the Conqueror between 1451 and 1469. The Ottomans drastically changed the appearance of the city. They organised the Old Bazaar, with its caravanserais, mosques and baths.
In the cadastral register of 1451–52, the Skopje neighbourhood Gjin-ko (Gjinaj), is mentioned, being named after the medieval Albanian Gjini family. The neighbourhood displayed mixed Christian Albanian anthroponymy with cases of Slavicisation present (e.g. Palić; Pal + Slavic suffix ić). During this time period, a number of timariots of the city are recorded as bearing the name Arnauti (meaning Albanian) alongside a Muslim name, i.e. Hamza Arnauti, Shahin Arnauti, Jusuf Arnauti. Another group bore Slavic Christian names, whilst also bearing the surname Arbanas/Arnaut, i.e. Bogdan Arbanas, Bogoslav Arbanas, Milosh Arbanas, Bozhidar Arnaut, etc. These individuals are noted as not having the Slavic appellatives došlac, prišlac or uselica, which were given by Ottoman authorities to new settlers of a given region, likely indicating they were locals. In the year 1451 or 1453 a neighbourhood was registered bearing an Aromanian name, Mahalle-i Todor Vlaja-Vlaha. Amongst the 45 family heads of this neighbourhood, Christian Slavic and Albanian anthroponyms were recorded (Gjon-çe, son of Noriç, Koljko Bibani, Tusho, son of Rada, etc.), whilst a sizeable number of individuals bearing mixed Slavic-Vlach anthroponyms are also registered, such as: Petko, son of Vllah (Iflak), Petru, son of David, Andreja, kozhuhar, Nikul Çikun, etc.
In the mahallah Ahrijan Hasan in the year 1451 or 1453, a head of the family from the noble Albanian Muzaka family, who had converted to Islam, was re-registered amongst the Muslim heads of the family. In the other register of 1467/68, now in the Christian mahallah named Svetko Samarxhi, amongst the 29 heads of families with Slavic Christian anthroponyms, a number also carried Albanian anthroponyms. In the neighbourhood of Jazixhi Shahin, amongst the residents with Muslim names, the head of the family was registered only with the surname Zenebishi, without mentioning his social position or his profession, indicating a higher social status. This may suggest a relation to Hasan Bey Zenebishi, a descendant of the Zenebishi family and the Soubashi of the Nahiyah of Kalkandelen. Individuals bearing Albanian anthroponyms, be they in conjunction with Islamic, Slavic or Christian ones, also appear in the neighbourhoods of Kasim Fakih, Dursun Saraç, Kujumxhi Mentesheli, Çerep, Jandro, Stanimir, Vllah Dançu and Rela. A number of Sipahis were also of Albanian origin, with these individuals holding timars in areas which had a Christian Albanian symbiosis with Slavic anthroponyms in the vicinity of Skopje. The defters noted that these were old sipahis, likely having been landowners. These individual Sipahis were closely related by descent and blood, and taking account kinship ties, even though they had heterogeneous, Christian, Slavic and Oriental names, they appear to have been Albanians. Some have names indicating their origin, such as Shimerd Vardarli from Skopje, making it likely these timariotes were locals.
In the 1467/68 and 1568/69 defter, Skopje had a majority Muslim population. The 1467/68 defter recorded 33 Muslim town quarters with 637 houses whereas the Christians had 11 quarters with 277 houses. In 1568/69 there were 57 Muslim quarters and only 9 Christian.
Around 1529, the Christians of Skopje were mostly non-converted Slavs and Albanians, but also Ragusan and Armenian tradesmen. Mustafa Pasha Mosque, built in 1492, is reputed to be "one of the most resplendent sacral Islamic buildings in the Balkans." In 1535 all churches were demolished by decree of the Ottoman governor. In 1555, the city was hit by another severe earthquake, collapsing much of the city. The Old Bazaar of Skopje, the columns of the Stone Bridge, and the murals in the upper parts of the Church of St. Panteleimon, Gorno Nerezi were all severely damaged. Some modern sources estimate this earthquake to have been a Category XII (Extreme) on the Modified Mercalli intensity scale, although others believe this is an overestimate.
In 1623–1624, Pjeter Mazreku, a Roman Catholic prelate, reported the town was inhabited by "Turks (Muslims), the majority of them being Albanians, the rest are of Asiatic origin", Mazreku further wrote, "there are also Jews, Serbs and some Greeks in the town". In the Ottoman period, Turks was used by Christian sources as a term for all Muslims, regardless of ethnic background. Sources from the years of 1689–1690 considered the town of Shkupi (Skopje) during those periods as part of Albania.
Until the 17th century, Skopje experienced a long golden age. Around 1650, the number of inhabitants in Skopje was between 30,000 and 60,000, and the city contained more than 10,000 houses. It was then one of the only big cities on the territory of future Yugoslavia, together with Belgrade and Sarajevo. At that time, Dubrovnik, which was a busy harbour, did not even have 7,000 inhabitants. The city severely suffered from the Great Turkish War at the end of the 17th century and consequently experienced recession until the 19th century. In 1689, the Habsburgs seized Skopje which was already weakened by a cholera epidemic. The same day, general Silvio Piccolomini began the Skopje fire of 1689, attempting to end the epidemic. It is however possible that he wanted to avenge damages that the Ottomans caused in the Battle of Vienna in 1683. Skopje burned for two days but the general himself perished of the plague and his leaderless army was routed. The Austrian presence in Macedonia motivated Slav uprisings. Nevertheless, the Austrians left the country within the year and the Hajduks, the leaders of the uprisings, had to follow them in their retreat north of the Balkans. Some were arrested by the Ottomans, such as Petar Karposh, who was impaled on Skopje's Stone Bridge.
After the war, Skopje was in ruins. Most of the official buildings were restored or rebuilt, but the city experienced new plague and cholera epidemics and many inhabitants emigrated. Ottoman Empire as a whole entered into recession and political decline. Many rebellions and pillages occurred in Macedonia during the 18th century, either led by Ottoman outlaws, Janissaries or Hajduks. An estimation conducted by French officers around 1836 revealed that at that time Skopje only had around 10,000 inhabitants. It was surpassed by two other towns of present-day North Macedonia: Bitola (40,000) and Štip (15–20,000).
Skopje began to recover from decades of decline after 1850. At that time, the city experienced a slow but steady demographic growth, mainly due to the rural exodus of Slavic Macedonians. It was also fuelled by the exodus of Muslims from the Principalities of Serbia and Bulgaria, which were gaining autonomy and independence from the Empire at that time. During the Tanzimat reforms, nationalism arose in the Ottoman Empire and in 1870 a new Bulgarian Exarchate was established and its separate diocese was created, based on ethnic identity, rather than religious principles. The Slavic population of the bishopric of Skopje voted in 1874 overwhelmingly, by 91% in favour of joining the Exarchate and became part of the Bulgarian Millet. Economic growth was permitted by the construction of the Skopje-Salonica railway in 1873. The railway station was built south of the Vardar and this contributed to the relocation of economic activities on that side of the river, which had never been urbanised before. Because of the rural exodus, the share of Christians in the city population increased. Some of the newcomers became part of the local elite and helped to spread nationalist ideas. In 1877, Skopje was chosen as the capital city of the new Kosovo Vilayet, which encompassed present-day Kosovo, north-western Macedonia and the Sanjak of Novi Pazar.
In statistics gathered by Bulgarian ethnographer Vasil Kanchov in 1900, the City of Skopje was inhabited by 31,900 people, of whom 15,000 were Turks, 13,000 Christian Bulgarians, 1,920 Romani, 800 Jews, 450 Vlachs, 150 Christian Albanians, 50 Christian Greeks, 30 Circassians and 500 inhabitants of various other ethnicities. Kanchov wrote in the same year that many Albanians declared themselves as Turks. In Skopje, the population that declared itself Turkish "was of Albanian blood", but it "had been Turkified after the Ottoman invasion, including Skanderbeg", referring to Islamisation. Bulgarian literary historian Yordan Ivanov wrote in 1915 that Albanians, since they did not have their own alphabet, due to a lack of consolidated national consciousness and influenced by foreign propaganda, declared themselves as Turks, Greeks and Bulgarians, depending on which religion they belonged to. Albanians were losing their mother tongue in Skopje. German linguist Gustav Weigand described that Skopje's Muslim population of "Turks" or "Ottomans" during the late Ottoman period were mainly Albanians who spoke Turkish in public and Albanian at home. In 1905, the city had 32,000 inhabitants, making it the largest of the vilayet, although closely followed by Prizren with its 30,000 inhabitants. At the beginning of the 20th century, local economy was focused on dyeing, weaving, tanning, ironworks and wine and flour processing.
Skopje was one of the five main centres of the Internal Macedonian Revolutionary Organisation when it organised the 1903 Ilinden uprising. Its revolutionary network in the region led by Nikola Pushkarov was not well-developed and the lack of weapons was a serious problem. At the outbreak of the uprising, the rebel forces derailed a military train. On 3 and 5 August respectively, they attacked an Ottoman unit guarding the bridge on the Vardar River and fought a battle in the St. Jovan monastery. In the next few days, the band was pursued by numerous Bashibozuks and moved to Bulgaria.
Following the Young Turk Revolution in 1908, the Ottoman Empire experienced democracy and several political parties were created. However, some of the policies implemented by the Young Turks, such as a tax rise and the interdiction of ethnic-based political parties, discontented minorities. Albanians opposed the nationalist character of the movement and led local uprisings in 1910 and 1912. During the latter, they managed to seize most of Kosovo and took Skopje on 11 August. On 18 August, the insurgents signed the Üsküb agreement which provided for the creation of an autonomous Albanian province, and they were amnestied the day later.