Help Center › Cloudflare

Can I use Cloudflare on my root domain (yourdomain.com)?

Yes. Cloudflare can proxy your root domain (yourdomain.com) as well as www and any other subdomain, whatever the record type (A, AAAA or CNAME). Just set the record's Proxy status to Proxied (orange cloud) in Cloudflare's DNS settings.

It's still a good idea to pick one main address for your site and redirect the other to it, so visitors and search engines see one version. In cPanel, go to Domains > Redirects to redirect www.yourdomain.com to yourdomain.com (or the other way round), or see Set Up URL Redirects.