Working Keywords into Your Pages

Search sites have different ways of gathering information on the content of Web sites:

Some search sites are put together by human effort. People visit Web sites that have been submitted to the search site and then manually categorize those sites.
Other search sites are fully automated. Programs called robots or spiders surf the Web, cataloging their findings and adding Web pages to the search site’s database. Robots and spiders don’t just note the URL of a page, though. They also index all the words on the page (except for words like a, an, the, for, and so on).

When someone runs a search, the search terms are compared with the indexed words. Links to whatever sites match the search terms are then shown to the person doing the searching.

In addition to the words in the text of your page (and sometimes in the alt text fields of images and other elements as well), search engines also index meta keywords.

The following sections give you the lowdown on incorporating keywords into your site.

Adding meta tags

META is one of the most versatile elements in HTML because it’s one of the most poorly defined ones. Some would just say it doesn’t have many limits. Its name and content attributes enable you to put many types of information into your HTML documents.

META always goes within the HEAD element, and it has no end tag.

You can have all the META elements ...

Get Building a Web Site For Dummies®, 3rd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.