Google and other search engines extract a great deal of information about a web page by examining the terms and phrases that it contains. Using that data they can and, from a group of pages, about a site as a whole. Of course, they learn something from the frequency of certain terms and words, but that’s not the only thing they weigh.
Writing well for search engines is an art cum science. SEOs can only make very educated guesses as search engines cleverly guard their algorithms. In general, however, writing well for the search engines is very similar to writing well for your site visitors. So there is a definite relation between making a site friendly for search engine spider and making it friendly for your site visitors.
If you want to optimize your on-page text for higher search engine rankings, here are some basic rules to remember:
Make sure the main keyword orphrase for which you wish to score higher in search engine ranking is featured prominently on your web page. Don’t bother too much about measuring your keyword density; its importance is arguable at best. However the general frequency of the term can help boost your rankings.
Keep all of the text on your page of high quality and related to the topic. Yes, search engines like Google indeed look for high quality writing; they are capable of performing some sophisticated analysis of the words on your web pages. You don’t  just have to please the artificial intelligences, but also the human ones; as search engines have teams of researchers who work on identifying and describing the common elements in high quality writing. You don’t have to be a literary genius, but remember that good writing is one of those things that both your visitors and the search engines will appreciate.
Structure your document so that it flows from broad to narrow topics. This is very important for making your site search engine as well as visitor friendly. You may start with a description of the content, so that both the spiders and your human visitors know what to expect. It improves the readability of the entire web page. There may be situations in which this would not be an appropriate way to structure the page; in such cases, you can disregard this advice.
It is also important to keep the text of your document together. Many SEO experts say that it is better to use cascading style sheets (CSS) rather than table layouts for this reason. CSS facilitate keeping the text flow of the document together and prevent the text from being broken up by coding. You can achieve this with tables too; just ensure that text sections (i.e. content, ads, navigation, and so forth) flow together inside one table or row. You should also refrain from having too many “nested” tables that make for broken sentences and paragraphs.
There was a time when text layout and keyword usage and its frequency in a document were very important, but that is no longer true. Do they still make a difference? Yes, to some extent; but there is no reason to obsess over keyword placement or text layout any longer.