As search engines operate in a highly automated way it is often possible for webmasters to use methods and tactics not approved by search engines to gain better ranking. These methods often go unnoticed unless an employee from the search engine manually visits the site and notices the activity, or a change in ranking algorithm causes the site to lose the advantage thus gained. Sometimes a company will employ an SEO consultant to evaluate competitor's sites, and report "unethical" optimization methods to the search engines.
So-called "unethical" methods may include:
Keyword spamming (or keyword stuffing) involves the insertion of hidden, random text on a webpage to raise the keyword density or ratio of keywords to other words on the page. Hiding text out of view of the visitor's screen is done in many different ways. A popular technique is text colored to blend with the background. Using CSS "Z" positioning to place text "behind" an image -- and therefore out of view of the visitor -- is also common. Other ways include using CSS absolute positioning to have the text positioned several feet away from the page center and, again, out of physical view of the visitor but plainly text that any search engine would pick up in a crawl of the page. Invisible text is a bad idea, as of 2005, because top search engines apparently can detect it.
Abusing NOSCRIPT tags is another way to place hidden content within a page so that the search engines will index it, but the visitor won't see the content. NOSCRIPT tags are also a valid optimization method for displaying an alternative representation of JavaScript content, such as dynamic methods. The NOSCRIPT tags is not unethical by itself, only if misused.
The inserted text sometimes includes words that are frequently searched (such as "sex") even if those terms bear little connection to the content of the page. The goal in these cases is plainly to increase traffic at all costs whether that traffic is relevant or not. Once traffic comes to the page, the unethical webmaster may hope to monetize the traffic by displaying ads.
Spamdexing is the promotion of irrelevant, chiefly commercial pages through abuse of the search algorithms. Many search engine administrators consider any form of search engine optimization used to improve a website's page rank as spamdexing. However, over time a widespread consensus has developed in the industry as to what are and are not acceptable means of boosting one's search engine placement and resultant traffic.
Cloaking refers to any of several means to serve up a different page to the search-engine spider than will be seen by human users. It can be an attempt to mislead search engines regarding the content on a particular web site. It should be noted, however, that cloaking can also be used to ethically increase accessibility of a site to users with disabilities, or to provide human users with content that search engines aren't able to process or parse. It is also used to deliver content based on a user's location; Google themselves use IP delivery, a form of cloaking, to deliver results.
Link spam is the placing or solicitation of links randomly on other sites, placing a desired keyword into the hyperlinked text of the inbound link. Guest books, forums, blogs and any site that accepts visitors comments are particular targets and are often victims of drive by spamming where automated software creates nonsense posts with links that are usually irrelevant and unwanted.
The following techniques are also widely acknowledged as being spam, or "black hat":
Some SEOs argue that the terms ethical and unethical should not be applied to the work they do. They maintain that on the principle of basic freedom everybody should be free to post whatever they choose on a site they own, as long as they stay within the law. The responsibility to block search engines access to that content is not one the webmaster should automatically assume. SEOs then explain that typically search engines visit sites uninvited and help themselves to the entire content of that site. Should the search engine then apply some software to "digest" that content and use it in their search results (often monetized with their own advertising) then pinning an "unethical" label on the webmaster is neither fair nor accurate. The flip side is that when a webmaster submits a site to a search engine he is actually inviting the search engine over. However, nowadays, the invitation is unnecessary as search engine spiders are aggressive in finding links to new pages and in crawling that new content, often within hours or minutes, unless they have specifically been excluded by a webmaster-prepared robots.txt file, or a robots exclusion meta tag.