After studying medicine at Oxford, Locke served the Earl of Shaftesbury as a physician, and followed him to France in 1675. There he spent four years studying Continental philosophy, especially that of Descartes.
On his return, Locke worked with Shaftesbury to block the succession of James, Duke of York, later James II, from the throne -- a controversial issue since the Restoration of Charles II. They were unsuccessful, and both were forced to flee England: Locke lived in Holland from 1683 until James II's overthrow in 1689.
In the following year appeared Locke's most important work, An Essay Concerning Humane Understanding. The central concern of the Essay is epistemology, the means by which we come to knowledge. Locke argued against the idea of "innate ideas," arguing instead that the mind is analogous to a blank slate, a tabula rasa, on which the senses make impressions: the importance of such experience in his philosophy is the origin of the term empirical.
Sensory experience, though, provides only one kind of idea, sensation; reflection, the other, is the mind's combination and comparison of the various sensory impressions. As a result, one has no direct knowledge of the physical world, but only of the ideas (whether sensations or reflections) produced by them. Locke devotes much of his Essay to the relationship between ideas and objects. His philosophy was a development of Bacon's methods, and provided the first systematic account of an empiricist philosophy and psychology.
His most important political work also appeared in 1690, the Two Treatises of Government; there he argues that the function of the state is to protect the natural rights of its citizens, primarily to protect the right to property. Though he challenged Thomas Hobbes on the nature of primitive society -- for Hobbes it was "nasty, brutish, and short," while for Locke it was more rational, tolerant, and cooperative -- he agreed with him on the origin of the social contract, an implicit agreement between everyone in a society to respect a legal authority, a supreme sovereign, so as to enable the pursuit of happiness.
During the next few years of relative retirement, Locke continued his involvement in political affairs, and hosted many important visitors, including Sir Isaac Newton. In 1693 he wrote an influential tract, Some Thoughts Concerning Education, to which Wollstonecraft refers in A Vindication of the Rights of Woman, chapter 1.
Locke's influence on the philosophy and political thought of the eighteenth century was without rival. His influence on Hume and Hartley was considerable, and his Two Treatises of Government, by advocating the removal of a ruler who fails to live up to his end of the social contract, made him an important figure among the intellectuals of the American war of independence: see, for instance, the first two paragraphs of the Declaration of Indepdendence. Volney addresses his theory of the association of ideas in "Volney's Answer to Dr. Priestley."