Well... you have to make a redirect from HTTP to HTTPS (preferable a 302 redirect), which covers the whole site.,
This can be done in the config of your webserver. For Apache you can e.g. add this to your .htaccess (or any other config file if you run a root server):
Code:
RewriteCond %{HTTPS} !=on
RewriteRule ^(.*)$ https://www.XXXX.de/$1 [L,R=301]
(of course replace the domain with the domain you want to redirect to)
Additionally you can send a specific header,
HSTS, which forces the clients (aka browsers) to directly connect to the HTTPS version of your site even if they receive a HTTP link (or something which tries to access to your site) later. An example for Apache to do this is this:
Code:
Header add Strict-Transport-Security: "max-age=15768000;includeSubdomains"
Attention: Please note that the number of max-age parameter are seconds. 15768000 seconds are a half year. This is a recommend value, but please note that you have to offer HTTPS in this time. Otherwise your user see an error and can't connect to the side.
However you can change the time (may-age) at any time and e.g. set it to 0. All clients which receive the new header (over HTTPS of course) will update the time. And if it's set to 0 you can later remove the support for HTTPS if you really plan to do so.