The Ottoman Empire joined the Central Powers to form the Triple Alliance with the signing of the August 1914 Turco-German Alliance. Turkey formally entered World War I on October 28, 1914, with the bombing of Russian Black Sea ports. The Triple Entente, or Allied Powers, declared war on the Ottoman Empire on November 4.
Two major factors led to Ottoman involvement on the side of the Central Powers: German pressure and the opportunism of Turkish minister of war Enver Pasha. Other motives for joining the Central Powers were the German victories early in the War and Turkey's friction with the Triple Entente. Germany's aim was clear: to keep Turkey from joining the enemy (and by gaining Ottoman support, encourage Romania and Bulgaria to enter the Alliance). The German military mission of 1913 to Turkey under Liman von Sanders organized the Turkish army and navy under German leadership and brought forth the Turco-German Alliance. The secret treaty (only five people in Turkey were aware of it, one being Enver Pasha) was signed 2 August 1914.
The Allies had strategic interests in the Turkish Straits but failed to provide a coherent defense of Turkey from Germany. To that extent, Turkey was driven into the Turco-German alliance; but Turkish leadership, fearful of disintegration of the Ottoman Empire, was divided on a course of action. Turkish ambassador in Paris Rifat Pasha advised that neither side would hesitate to dismantle the Empire. According to Rifat, Germany was not as strong as Enver Pasha perceived and considered Turkey to be merely a pawn. Nonetheless, Enver Pasha defied Rifat's pleas to avoid alliance with either side and took what he saw as an opportunity to claim a victory in war.
Enver Pasha chose to ally Turkey with the Central Powers, justifying the alliance by citing Germany's early victories in the War. Being on the winning side would provide the opportunity to forge a swift victory over neighboring enemies and avoid the imminent disintegration of the Ottoman Empire.
Alliance with the Central Powers appealed more to Turkey than alliance with the Allied Powers for additional reasons. Friction with the Entente came on two levels: firstly, Turkey and the Allies clashed over Turkey's harboring of German warships and, secondly, over Russia's interest in the Turkish Straits. On top of a long-standing objective to possess that territory, the Balkan Wars caused Russia to fear loss of access to the straits in 1912. Then in 1913, Russia threatened to occupy Ottoman territory if German military under Liman von Sanders was not removed. Russia was an archenemy and relations with the other Allied Powers were weak.
Encyclopedia Britannica. 15th ed. Macropaedia, vol. 28. Chicago, 1992.
Howard, Harry N. The Partition of Turkey: A Diplomatic History, 1913-1923. (New York; H. Fertig, 1966.)
Macfie, A. L. Profiles in Power: Ataturk. (London and New York; Longman, 1994).