I'm attempting to redirect incoming demands to https://www.domain.com/ and all sorts of https://www.domain.com/ and getting little trouble. Techniques I attempted:

  1. Adding this line: Redirect permanent / https://www.domain.com/ to my httpd.conf is leading to a lot of redirect

  2. Using .htaccess to redirect with mod_rewrite is ending in 302 Moved page having a damaged link.

Things I want is:

  1. Redirect all demands to https://www.domain.com/, including http://www.domain.com/register and pages like this to https version

I have looked many threads about this however they don't appear to use to my setup. How must i approach this?

LMGTFY. It is going like:

RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI}

Source: http://systembash.com/content/force-https-ssl-access-url-apache/