How to add the HTTPS protocol

At first you need to adjust DNS on CloudFlare.

Then you need to switch on all traffic caching on Cloudflare.
In the Cloudflare dashboard: the "DNS" tab in the top menu and the active cloud icons under the "Status" column in the "DNS Records" table.
The icons in front of the main domain and subdomain must be active.
Switch on the SSL in the tab Crypto.
In Cloudflare: the "Crypto" tab in the top menu and the "SSL" dropdown set to "Flexible".
Go to the tab Page Rules and click on the button 'Create Page Rule'
In the Cloudflare dashboard: the "Page Rules" tab in the top menu and the "Create Page Rule" button on the right.
Put in the name of the domain and a slash with a asterisk. Click on Add a Setting, choose SSL, then Flexibity. Click on [Save And Deploy]
In Cloudflare, the "If the URL matches" input field, the "SSL" dropdown and "Select SSL Setting" dropdown under "Then the settings are:", and the "Save and Deploy" button in the "Create a Page Rule" modal window.
If everything is doing correctly, you'll see the screen like this
In the Cloudflare dashboard: the "Page Rules" tab showing a configured rule for a domain with the "SSL: Flexible" setting enabled.
And add the rule to redirect all requests from www to the main domain.
In Cloudflare, the "If the URL matches" field, the "Forwarding URL" and "301 - Permanent Redirect" settings, and the destination URL field in the "Create a Page Rule" modal window.
Republish your website.

If you export your project, change http:// to // in the code.
In Cloudflare, the "Page Rules" section with configured redirect and SSL rules, and the "Create Page Rule" button.
Made on
Tilda