D
D
Dmitry Dmitriev2020-09-14 12:46:58
WordPress
Dmitry Dmitriev, 2020-09-14 12:46:58

How to remove a redirect in WordPress: from site goes to https://site, and then also to https://www.site?

How to remove a redirect in WordPress?
Analysis through Gtmetrix shows that when the main page of the site is requested, 2 redirects occur:

  • с http://site на https://site
  • а потом https://site на https://www.site


Thank you!

Answer the question

In order to leave comments, you need to log in

2 answer(s)
M
Michael Kim, 2020-09-14
@budikov

Find out where the redirect occurs:
a) plugins (they must be disabled)
b) view the site settings
c) view the control panel settings.
Most likely, the address https://site is set in the admin panel , and the redirect is still performed by the server. On the timeweb, for example, it is possible to add a redirect.

V
Viktor Taran, 2020-09-14
@shambler81

It doesn't matter at all, I'm tired of talking about it.
You can remove it quite easily,
combine the www and https redirect into one, but there is no point in this!

RewriteEngine On
RewriteCond %{HTTPS} off [OR]
RewriteCond %{HTTP_HOST} ^www\.
RewriteRule (.*) https://site.ru/$1 [L,R=301]

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question