The Statement of Purpose should describe your experience with academic and scholarly work and your aptitude for future contributions.
UC Berkeley provides an excellent outline of the material that should go into this essay, describing four essential components: 1) An introduction to yourself and your interests and motivations; 2) A summary of your undergraduate career and previous graduate school experience if any; 3) A discussion of your recent activities and their relevance to what you want to do in graduate school; and 4) an elaboration of your academic interests. You can find the UC Berkeley instructions here. You can start your Statement of Purpose by using this outline and developing a list of things that belong within each category and then create an essay from your outline. You will also want to include mention of the professor(s) with whom your work aligns and who might act as mentors, as well as add a sentence or two about your intended career and professional goals.
Of course, this essay is going to be very different depending on the student and the program/degree for which you are applying. A chemistry major applying for a PhD will write something very different then a environmental activist applying for a Masters in Public Policy. However, the basic structure and information will be the same. The length of the essay will depend on the school and program but here are some general guidelines. UC Davis asks for an essay that is 4000 characters including spaces. The UC Berkeley instructions recommend approximately 500 to 1000 well-selected words that will fit on 1-2 single space pages in 12 point font. The UCLA instructions suggest a 1500 word maximum. Below is a list of statements for various programs.
One of the best things you can do once you have finished your essay is to have someone who is already accomplished in that discipline read it. If you are applying for a Masters in Social Work have a social worker read your essay, if you are applying for a PhD in Anthropology ask an anthropologist to read your essay, and so on. This is particularly important for those students who want to go into a scholarly discipline. You don’t have to be an expert (or you wouldn’t be applying for an advanced degree anyway), but you do need to sound like an insider to the discipline. There isn’t time for remedial work in most graduate programs (although you can sometimes catch up on pre-requisites) and admissions committees want to insure that you will be a fit for their department.