Support » Fixing WordPress » www redirect subdirectory

Viewing 2 replies - 1 through 2 (of 2 total)
  • Maybe try this in htaccess before your wordpress stuff or google “force www htaccess” there are different ways to write these lines.

    RewriteEngine On
    RewriteCond %{HTTP_HOST} !^www\.example\.com$ [NC]
    RewriteRule .?{REQUEST_URI} [R=301,L]\

    @dralezero — the 3 lines you suggested worked perfectly for me with one exception. My wp-admin site was no longer accessible, as the redirect prevented me from getting to

    Is there a way to exclude the wp-admin site from the redirect? Or can I access the admin site from somehow?


Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘www redirect subdirectory’ is closed to new replies.