SiteLint

  1. Home
  2. Docs
  3. SiteLint
  4. Guidelines
  5. Best practices for SEO

Best practices for SEO

Print this article
Pads with one letter from the inscription "SEO Audit" on each
On this page
  1. General
    1. Google
    2. Bing
  2. WordPress
  3. Performance – rendering and loading
  4. Quality

General

Tell search engine crawlers which URLs the crawler can access on your site using robots.txt

A robots.txt file can be found at the root of your website. As an example, for the website www.example.com, the robots.txt file is located at www.example.com/robots.txt. The robots.txt file is a plain text file that adheres to the Robots Exclusion Standard. One or more rules are contained in a robots.txt file. Each rule restricts or allows access to a single file location on the domain or subdomain where the robots.txt file is hosted. Unless you declare otherwise in your robots.txt file, all files are assumed to be crawlable.

See Sitelint robots.txt file content.

Build and submit a sitemap A sitemap is a file that contains information about your site’s pages, videos, and other assets, as well as the relationships between them. This file is read by search engines in order to crawl your site more efficiently. A sitemap tells the search engine which pages and files on your site you believe are important, as well as provides valuable information about these items. For example, when was the page last changed, and if there are any different language versions of the page. See the Sitelint sitemap file.
Creating the page title

Once you have a specific topic, enter it in several search engines and see how users define it. Examples a few example for sentence Best practices for SEO.

Google

Google search results and section "People also ask": What are your top 5 SEO recommendations? What are the 3 core must haves of SEO? How to optimize SEO in 2023? How to master SEO 2023?
Google search results with the bottom part that contains suggested keywords

Bing

Bing keywords suggestion

WordPress

Create canonical URL for the category page

WordPress auto-generates the canonical URL link for the single post and page, but not for the Category page type. To achieve that you can add the following code to your functions.php:

function addCanonicalLinkForCategoryPage()
{
  if (is_category()) {
    $categories = get_the_category();
    $categoryId = $categories[0]->term_id;

    echo '<link rel="canonical" href="' .  get_category_link($categoryId) . '">';
  }
}

add_action('wp_head', 'addCanonicalLinkForCategoryPage');

Performance – rendering and loading

Delay loading non-critical resources In most cases we are loading everything right now. However, that impacts on the loading and rendering performance. Various browsers have various limits for maximum connections per host name. If the connection limit is reached, further requests will wait until connections free up. Consider reviewing those resources that can be loaded with delay. Example: analytics.
Enable protocol HTTP/2 The primary goals for HTTP/2 are to reduce latency by enabling full request and response multiplexing, minimise protocol overhead via efficient compression of HTTP header fields, and add support for request prioritisation and server push.
Static assets
  1. Keep HTML file as small as possible.
  2. Minify and compress JavaScript and stylesheets CSS. Compression could be done automatically by enabling gzip or brotli compression for all static assets.
  3. Try combine all scripts or styles into one file. This will reduce total amount of HTTP requests.
  4. Configure output cache and cache expiration time. Example for Apache cache or Nginx cache settings.

Read also 8 tips to speed up image loading.

Quality

Delay loading non-critical resources In most cases we are loading everything right now. However, that impacts on the loading and rendering performance. Various browsers have various limits for maximum connections per host name. If the connection limit is reached, further requests will wait until connections free up. Consider reviewing those resources that can be loaded with delay. Example: analytics.
Enable protocol HTTP/2 The primary goals for HTTP/2 are to reduce latency by enabling full request and response multiplexing, minimise protocol overhead via efficient compression of HTTP header fields, and add support for request prioritisation and server push.
Static assets
  1. Always provide an alternative description (attribute alt) for the image. It will not only help screen reader users, but also search engines to understand what exactly is on the image.
  2. Implement Open Graph and Schema.

    Open Graph meta tags are snippets of code that control how URLs are displayed when shared on social media.

    Schema markup (schema.org) is a structured data vocabulary that helps search engines more accurately understand the information on your website that normally HTML can’t provide enough tags or elements to describe the content more precisely. See example schema for the product.

Was this article helpful to you? Yes No
SiteLint Audits: Monitoring in real-time Accessibility, Performance, Privacy, Security, SEO, Runtime Errors and Console Logs