For the TL;DR, if you are getting error like this:
Solution: the page is not working. redirected you too many times for wordpress cloudfare site after CDN setup when the wp site is hosted with bluehost/hostinger
- Login to your cloudflare dashboard home
- Click on the respective site which will lead you to the overview section of that site
- Click on the SSL/TLS section on the left hand side panel
- In the SSL/TLS setting page, if its in Flexible mode switch it to Full (strict) , in case its in Full(strict) mode switch it to Flexible mode.
- That’s it.
Bonus tips, if you are not sure if you have setup your cloudflare CDN properly or not, read below:
Cloudflare cdn configuration for bluehost/hostinger hosted WP site without plugin
- Go to cloudflare.com
- Click signup
- Choose free plan
- Create account by putting your email ID and setting up the password
- go to your email and confirm your email by clicking the link you will get inside an email from cloudflare
- Click on Add a website or application
- Enter your domain name (example.com) without putting any prefix such as http/s/www.or prefix such as / etc.
- click add site
- Scroll down and select free plan again.
- Click continue
- It will lead you to all the DNS records cloudflare could fetch including your domain email, get at least the email records / ip confirmed from your hosting service provider.
- Click Continue
- You now will get to nameserver url copy them.
- Go to your domain registrar dashboard , i.e., namecheap, godaddy etc.
- click on the domain name and go to manage (for namecheap) or something equivalent
- Scroll down to the NAMESERVERS section
- Change to Custom DNS , if not done already.
- you should be able to see two nameserver urls fields
- Paste the copied nameserver urls from cloudflare, and click Done.
- Wait for around 30 minutes or so till the time you see your site/domain in your cloudfare dashboard marked as active.
- Check if your site is loading fine, if yes, great job, you just finished your wordpress or any other site integration with cloudflare.
- If you are seeing the error: redirected you too many times for wordpress cloudflare website after the cloudflare CDN setup, you know how to fix it.