Support » Fixing WordPress » 301 redirect from http to https

  • I have just installed a SSL certificate on my site. I changed my address from http to https inder the admin>general options, but now my PR does not exist. How do I set up a 301 redirect from http to https in my .htaccess file. I am not savy on this so please be nice. This is my .htaccess file now….

    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>

    # END WordPress

Viewing 5 replies - 1 through 5 (of 5 total)
  • pho

    (@pho)

    I am looking for an answer for the same problem. To make things worse, I would like to redirect only a couple of pages in my site.

    places

    (@places)

    RewriteEngine On
    RewriteCond %{HTTPS} !=on
    RewriteRule ^(.*) https://%{SERVER_NAME}/$1 [R,L]

    pho

    (@pho)

    It works to redirect a whole http site to a https site.

    Is it possible to redirect only one or two pages??

    places

    (@places)

    If you just want to redirect one or two pages set the rewrite rules like

    RewriteRule ^page1(.*) https://%{SERVER_NAME}/page1$1 [R,L]

    pho

    (@pho)

    Yes! It works!! Thank you, places!!

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘301 redirect from http to https’ is closed to new replies.