Redirecting from http to https in Apache

You should configure Apache Virtualhosts to do the job. RewriteMod isn't the appropriate solution for this case and .htaccess isn't either.

In your httpd.conf or equivalent use the following lines accordingly your needs. Edit it to your domain and site.

<VirtualHost *:80>
   ServerName www.example.com example.com
   Redirect permanent / https://example.com/
</VirtualHost>

<VirtualHost _default_:443>
   ServerName example.com
   DocumentRoot /usr/local/www/apache2/htdocs
   SSLEngine On

   ** Additional configurations here **

</VirtualHost>

Hope this clarifies the procedure.