If you have a secure (SSL, HTTPS) connection available for your website, even on another web host, it’s not a bad idea to redirect all of your visitors to the secure version of your website. This method can be achieved with multiple methods (if you’re using .htaccess, there is another tutorial for that here), but this tutorial will show you how to redirect by adding code to your .htaccess.
If you are using 000webhost, you will need to setup with Cloudflare to get SSL.
###How to redirect using Cloudflare page rules
- Open your Cloudflare dashboard and go to the Page Rules tab.
- Click on Create Page Rule.
- Enter your domain like in the screenshot (
http://*example.com/*), and replace the domain with your website. Click on Add A Setting and choose Always Use HTTPS. Then click Save and Deploy.
Success! You’ve just enabled a full HTTP to HTTPS redirect using Cloudflare! Now all your visitors will see secure content.