The Greek War of Independence (1821–1829) was fought to liberate Greece from three centuries of Ottoman occupation. Independence was secured by the intervention of the British and French navies and the French and Russian armies, but Greece was limited to an area including perhaps only one-third of ethnic Greeks, that later grew significantly with the Megali Idea project. The war ended many of the privileges of the Phanariot Greeks of Constantinople. After nine years of war, Greece was finally recognized as an independent state under the London Protocol of February 1830. Further negotiations in 1832 led to the London Conference and the Treaty of Constantinople; these defined the final borders of the new state.