Redirects and search for google: how to correctly redirect the pages of your site

Redirects and search for google: how to correctly redirect the pages of your site

The URL redirect is the process of transferring the old URL to a new one, which allows your visitors and google post to learn about the new page. Redirects are especially useful in the following cases:

  • You move the site to a new domain and want the transition to be as smooth as possible.
  • Users can get to your site through several different URLs. For example, if your main page is available in several ways (for example, https://example.com/home, http://home.example.com or https://www.example.com), it is better to choose one of these URLs as preferable (canonical) and use redirects for redirecting from other URL to the main.
  • You combine two sites and want to make sure that links to outdated URLs are redirected to the right pages.
  • You deleted the page and want to redirect users to a new one.

If you use platforms such as Blogger or Shopify, you may already have built -in solutions for redirects. Try to look for articles for help on the request "Redirects in Blogger".

Review types for your site in Google

Although users usually do not notice the differences between the types of redirects, Google uses redirects as a strong or weak signal about which URL should be canonical. The choice of the type of redirect depends on how long you plan to use the redirect and what page you want to see in the search results:

  • Constant redirects: show a new URL in the search results.
  • Temporary redirects: show the old page in the search results.

The following explains what methods of setting constant and temporary redirects are most effective for Google:

Constant redirects

Googlebot follows the redirect, and the indexing process uses the redirect as a strong signal, that the new URL should be canonical.

  • HTTP 301 (moved forever)
  • HTTP 308 (moved forever)
  • Meta Refresh (0 seconds)
  • JavaScript location

Temporary redirects

Googlebot also follows a redirect, but indexing uses a redirect as a weak signal about the canonical of the target.

  • HTTP 302 (found)
  • HTTP 303 (see another)
  • HTTP 307 (temporary redirect)
  • Meta Refresh (more than 0 seconds)

Server redirects for your Google site

To configure server redirects, access to server configuration files (for example, .htaccess for Apache) or tuning redirects using server scripts (for example, PHP) are necessary. You can create both permanent and temporary redirects on the server side.

Constant server redirects

If you need to change the page of the page so that it is displayed in the search results, we recommend using a constant server redirect when possible. This is the best way to ensure that Google-Poral and users fall on the right page. The status code 301 and 308 means that the page was forever moved to the new URL.

Temporary server redirects

If you need to temporarily redirect users to another page, use a temporary redirect. This will also help Google save the old URL in the search results for a longer period. For example, if the service on your site is temporarily unavailable, you can set a temporary redirect to redirect users to a page with an explanation of what is happening, without influencing the original URL in the search results.

The implementation of server redirects

The implementation of server redirects depends on your hosting, server environment or programming language on your site’s bachelor.

An example of a constant redirect using PHP:

header('HTTP/1.1 301 Moved Permanently');
header('Location: https://www.example.com/newurl');
exit();

An example of a temporary redirect using PHP:

header('HTTP/1.1 302 Found');
header('Location: https://www.example.com/newurl');
exit();

If you have access to a web server configuration file, you can configure the redirect rules yourself:

  • Apache: Use the Mod_rewrite module for more complex redirects. An example of a simple redirect:
  • # Постоянный редирект:
    Redirect permanent "/old" "https://example.com/new"
    # Временный редирект:
    Redirect temp "/two-old" "https://example.com/two-new"
  • Nginx: An example of a redirect for constant transfer:
  • location = /service {
     # для постоянного редиректа
     return 301 $scheme://example.com/about/service;
     # для временного редиректа
     return 302 $scheme://example.com/about/service;
    }

Meta Refresh and its HTTP-Equillians for your Google site

If you cannot realize server redirects on your platform, meta-shares can be an acceptable option. Google distinguishes between two types of meta-cores:

  • Instant meta-core: works immediately after loading the page in the browser. Google interprets it as a constant redirect.
  • Disractable meta-core: triggers after a time set by the user. Google interprets it as a temporary redirect.

JavaScript location redirects for your Google site

Google processes and performs JavaScript using Web Rendering Service after the URL has been fully processed. Use JavaScript redirects only if it is impossible to make server or meta-codium. Keep in mind that sometimes rendering may not pass successfully, and Google will not see Redirect.

Crypto core

If you cannot use standard redirect methods, add a link to a new URL with an explanation. This will help users find your new page. However, do not rely on Crypto cores, as they are not always understood by search engines.

Alternative versions of the URL on your site in Google

When you use a redirect, Google tracks both old and new URLs. One of these URLs will become canonical, depending on the type of redirect. For example, if you transferred the site to a new domain, Google can from time to time show the old URL in the search, although the new is already indexed.

If you need help to set the redirects on your site, you can contact the SEO.computer SEO compound on any issue on email info@seo.computer Or whatsApp +79202044461.

ID 102

Send a request and we will provide a consultation on SEO promotion of your website