Basic SEO for a website
SEO stands for Search Engine Optimization. When you optimize your website well, search engines rate it better and the page has a higher chance of appearing higher up when someone searches for the keyword.
Note (as of September 2026): Search engines do not use the keywords meta tag (see below) and the title attribute of images does not help search engines – the alt attribute is what matters. Google shortens titles and descriptions in the results by the width of the text. A sitemap.xml file is often created by the content management system itself today.
So if you sell, for example, shoes and someone searches for shoes, good SEO gives you a higher chance that they find you at all. A typical user looks at most at the second page of results, so being at the front pays off. SEO is of course not everything, but it is a solid base to build on. On top of it there are paid campaigns that show ads and bring people to your website. Paid activities are not the topic of this article.
The basis is to treat a website like an article or a thesis. A website is in fact nothing more than a text document that looks different, with images in the background and in the text. So every page must have some text with headings. We must write to the point (in an article about a product we write about the product, about the company we write about the company and so on).The key is to write original content and not copy other websites.
A search engine robot recognizes a copy and it can hurt you rather than help.
For headings we stick to the rule that a first-level heading is always on the page and only once. This heading has the largest font on the page, it should be above all the content of the page (leaving out the menu items in the header and so on) and above all it should say clearly what the page is about (for a product it is the name of the product, on the home page something that says what the website is about and so on). Lower-level headings can appear several times on a page, but again they should say clearly which part they introduce and what the text below them is about. A second-level heading is less prominent than a first-level heading but more prominent than a third-level heading and so on.
For images fill in the alt attribute, which helps the search engine robot understand what the image shows.
Filling in the meta tags (description, title, keywords) is just as important. The title is shown together with the description in the list of search results. Keywords are the words that say what the page is for (for a page selling Nike shoes it would be, for example, shoe, Nike, shoe shop and so on – simply what you would type into a search engine if you were looking for Nike shoes). Note: Google has ignored the keywords meta tag when ranking pages since 2009 – the text of the page, the title and the description are what matter. The description says in at most 2 sentences what the page is about. Google shortens long titles and descriptions, so the main message should come first.
Tools for choosing keywords, such as Google Keyword Planner in Google Ads, show how often people search for a word. Take their numbers with a grain of salt – nobody outside Google knows exactly how it ranks pages.
In the code we try to follow the semantics of the language. A website without errors is a plus for robots.
Set up the robots.txt file correctly
Have an up-to-date sitemap.xml file, which can be generated, for example, at xml-sitemaps.com.
It is important to have logical URLs.
If the URL is, for example, www.example.com/123_hello/, the robot does not know what it is about, but www.example.com/about-us/ makes sense both to the robot and to the user.
In general, the more specific you are in the content and in the code (the menu will not be a div but nav; text will not be just in some div but in a paragraph p; a heading will not be a div but really a heading, for example h2 and so on), the better the search engine robot can understand your page and rate it well. Without these details the robot will not know what the page means and will have no reason to show it as relevant in search results. The technical side is covered in more detail in the series Technical SEO.