The city was founded around 315 BC by the King Cassander of Macedon, on or near the site of the ancient town of Therma and twenty-six other local villages. He named it after his wife Thessalonike, a half-sister of Alexander the Great. It was an autonomous part of the Greek Kingdom of Macedon. After the fall of the kingdom of Macedon in 168 BC, Thessalonica became a city of the Roman Republic. It grew to be an important trade-hub located on the Via Egnatia and facilitating trade between Europe and Asia. The city became the capital of one of the four Roman districts of Macedonia.
When in 379 the Roman Prefecture of Illyricum was divided between East and West Roman Empires, Thessaloníki became the capital of the new Prefecture of Illyricum. The economic expansion of the city continued through the twelfth century as the rule of the Komnenoi emperors expanded Byzantine control to the north. Thessaloniki passed out of Byzantine hands in 1204, when Constantinople was captured by the Fourth Crusade. Thessaloníki and its surrounding territory—the Kingdom of Thessalonica—became the largest fief of the Latin Empire. The city was recovered by the Byzantine Empire in 1246 sold it in 1423 to Venice, which held the city until it was captured by the Ottoman SultanMurad II on 29 March1430.
During the Ottoman period, the city's Muslim and Jewish population grew. By 1478, Thessaloniki had a population of 4,320 Muslims and 6,094 Greek Orthodox, as well as some Catholics, but no Jews. By ca. 1500, the numbers had grown to 7,986 Greeks, 8,575 Muslims, and 3,770 Jews, but by 1519, there were 15,715, 54% of the city's population. The invitation of the Sephardic Jews expelled from Spain by Ferdinand and Isabella, was an Ottoman demographic strategy aiming to prevent the Greek element from dominating the city. The city remained the largest Jewish city in the world for at least two centuries, often called "Mother of Israel".
During the First Balkan War, the Ottoman garrison surrendered Salonika to the Greek Army, on November 9 November [O.S. 27 October] 1912. In 1915, during World War I, a large Alliedexpeditionary force landed at Thessaloniki as the base for a massive offensive against pro-German Bulgaria. In 1916, pro-Venizelist army officers, with the support of the Allies, launched the Movement of National Defence, which resulted in the establishment of a pro-Allied temporary government that controlled northern Greece and the Aegean, against the official government of the King in Athens, which lead the city to be dubbed as symprotévousa ("co-capital"). Most of the old town was destroyed by a single fire on 18 August [O.S. 5 August] 1917, accidentally sparked by French soldiers in encampments at the city. The fire left some 72,000 homeless, many of them Turkish, of a population of approximately 271,157 at the time. Thessaloniki fell to the forces of Nazi Germany on April 22, 1941, and remained under German occupation until 30 October1944. The city suffered considerable damage from Allied bombing, and almost its entire Jewish population was exterminated by the Nazis. Barely a thousand Jews survived. Thessaloniki was rebuilt and recovered fairly quickly after the war with large-scale development of new infrastructure and industry throughout the 1950s, 1960s and 1970s.