Subdomain using Cloudflare - All configured but not working


I searched all over the forums but, although there were a few similar questions, I didn’t find an answer to my problem.

My domain is using Cloudflare name servers.
I added an A record for a subdomain in Cloudflare pointing to the same IP address that I’m using in the main domain. I also created that subdomain in InfinityFree’s CPanel.

For example lets say I have a domain “” pointing to
I created the A record “sub” pointing to and then created the subdomain “” in InfinityFree’s Cpanel.

My Cloudflare configurations have SSL enabled both for my domain and first level subdomains. Accessing “domain . com” in the browser is working fine but when I access “sub . domain . com” I get the error " Error 525 ## SSL handshake failed".
It’s been more than an hour so I don’t think it DNS propagation.

Did I do something wrong?

Thanks in advance for your help.

I’ve just tested it using “” instead of “” and it’s working fine without SSL.

There must be something missing but I can´t figure where!

Any SSL installed for domain and subdomain? What is the SSL mode in CloudFlare?

Thank you for your reply.

I have one SSL certificate at Cloudflare valid for “” and “*”.
The SSL/TLS encryption mode is Full.

Can you please don’t use a placeholder and share your actual domain?

1 Like

You need to install SSL cert for domain and subdomain as well

If you see an SSL error from your browser, it could be one of two things:

  • The subdomain has Cloudflare enabled, but Cloudflare hasn’t issue the SSL certificate yet.
  • The subdomain does not have Cloudflare enabled, and you haven’t installed an SSL certificate on your subdomain.

I could tell you more, but given that you didn’t answer the questions in the topic template (notably Website URL), I can’t give you specific information.



I didn’t provide the URL because the site is far from finished. I also didn’t provide the subdomain because it will be private and it is password protected by an .htpasswd file. Besides, I didn’t think it was required because the names of these entities did not seem relevant to this problem. But here they go.


I’m sorry but I can only put 2 links in a post so I will have to reply in several posts.

I didn’t enable Cloudflare in Infinityfree CPanel. My domain DNS management is hosted by Cloudflare.
The SSL certificate issued by Cloudflare is valid for the domain and all first level subdomains as you can see here:

These certificates both exist in Infinityfree’s “Free SSL Certificate” panel. You can check that here:

And here:

The DNS entry for the subdomain exists in Cloudflare and is pointing to the same IP address as the domain:
(The forum doesn’t let me post the screenshot)

After creating the subdomain in Cloudflare, I also created it in Infinityfree’s CPanel:
(The forum doesn’t let me post the screenshot)

I also noted that the subdomain is accessible if I change the Cloudflare’s SSL/TLS encryption mode is from “Full” to “Flexible”. But I would really like to use it in the Full mode and the main domain works in the Full mode. The problem is only with the subdomain.

Thank you for your replies and please tell me if you need more info.

I don´t know if you can see all my posts because some were automatically classified as spam.

You need to install SSL cert for subdomain. Use InfinityFree SSL tool.

Hi KangJL,
Thank you for your reply.

I already did.
I mentioned it in a previous message but it had screenshots so it was flagged as spam and its unavailable.

No, you did not. Pls show TLS/SSL section for subdomain in Vpanel. The SSL cert for subdomain need to be installed in VPanel in order to use full mode.

I don’t know if the post will be flagged again but here it goes:

I am only interested with the screenshot from VPanel. What you are showing is not helpful at all.

You mean here?

I didn’t create a certificate here for the subdomain, but I didn’t do it for the main domain also and it’s working.
Besides, I tried to create one here and it throwed an error. When I searched for that error in Infinityfree’s knowledge base, it mentioned something about not accepting keys generated by Cloudflare.

Full mode will require SSL certs to be installed.

Use the InfinityFree SSL tool. Keys generated by Cloudflare will not work.

1 Like