Am ha'aretz means an "ignorant," or "boorish person." In a culture that has always prized learning highly, it is quite a put-down to call someone an am ha'aretz.
The literal meaning of the phrase is "people (am) of the earth (aretz)." To the rabbis of the Talmud, an am ha'aretz, by virtue of his ignorance, was deemed likely to be lax in his observance of the commandments. One common implication of this was that one couldn't count on an am ha'aretz separating tithes from his produce.
The rabbis argue about how you may recognise an am ha'aretz. Some of the possibilities are: one who doesn't say the Shema with its blessings morning and night; one who doesn't put on tsitsit or tefilin; one who has children but doesn't care to give them a Jewish education. The most stringent view is that even a person who learns Torah and Mishnah, but doesn't frequent Torah scholars, is to be considered an am ha'aretz; without learning face-to-face from a living sage, our knowledge is likely to be unreliable (Talmud Berachot 47b, Sotah 22a).
Today, am ha'artzut (the state of being an am ha'aretz) has spread on a scale that the sages never imagined. Knowing what an am ha'aretz is, and knowing that traditionally Jews strove with all their strength to avoid being one, may be a first step to remedying this.