Question

Wordpress Multisite is 301 redirecting subsites to main site

Posted January 1, 2022 76 views
WordPressUbuntu 20.04

I have wordpress multisite setup, and I also have lets encrypt setup. I have a few subsites with domains mapped. I added all the domains to letsencrypt using certbot. by adding -d domain1.com -d domain2.com in the commands

I did have an erroe message when it came to the redirect / no redirect issue.

The main site domain was setup before the subsites and the certbot was originally run on it’s own. I added additional domains after.

I can get to any domain of a subsite perfectly fine if I add https: in front. If I don’t, it redirects to the main site domain.

this site shows there is a redirect happening
https://check-your-website.server-daten.de/?q=thehockeydoctor.ca

But I can’t seem to figure out where or how so I can attempt to fix it.

Any ideas would be super helpful

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

×
Submit an Answer
1 answer

Hello, @intravista

If I understand correctly the subsites open fine via HTTPS, but if you access them via HTTP they will redirect to the main site. If you want to make the sites open via HTTP as well, then you can check if you have a 301 redirect rule that will forward all non HTTP requests to the main site.

In case you use Nginx this will be in the Nginx config file and if you use Apache then you should check the .htaccess files as well.

Hope that this helps!
Regards,
Alex