Multisite wp-admin redirecting to main wp-admin using NGINX

When I try to go to the wp-admin of any multi site, it redirects to the main wp-admin.

So if I go to example.com/multi-site-slug/wp-admin/ it redirects to example.com/wp-admin/

NGINX is being used as a reverse proxy.

I’m using the standard WordPress Multisite Subdirectory rules per the codex: https://wordpress.org/support/article/nginx/

If I take out this line in the conf file rewrite ^(/[^/]+)?(/wp-.*) $2 last;, it prevents the redirect but then media assets don’t serve properly on the multisites.

Read more here:: Multisite wp-admin redirecting to main wp-admin using NGINX

Leave a Reply

Your email address will not be published. Required fields are marked *