Cloudflare is a global network that sits between your website and its visitors. Every site we host is “behind” Cloudflare, which means visitors connect to Cloudflare first, and Cloudflare passes on only the traffic that should reach your site.
If you’ve ever looked at your domain’s DNS settings and seen Cloudflare, or seen a Cloudflare page while visiting a website, this is why.
What Does Cloudflare Do?#
Cloudflare does four main jobs for a website:
- Security: filters out attacks, bad bots and suspicious traffic before it reaches your site.
- Speed: stores copies of your pages, images and files in data centres around the world, so visitors load them from somewhere nearby.
- DNS: answers the question “where is this website?” quickly and reliably whenever someone types your address.
- SSL: provides the padlock (HTTPS) so connections to your site are encrypted.
How It Works#
Without Cloudflare, a visitor’s browser connects straight to the server hosting your website. Anyone, including attackers, can reach that server directly.
With Cloudflare, your domain’s DNS points visitors to Cloudflare’s network instead:
- A visitor types your address. Cloudflare’s DNS answers with one of its own addresses, not your server’s.
- The visitor connects to the nearest Cloudflare data centre. Cloudflare checks the request against its security rules.
- Cloudflare answers from its cache if it can. Images, styles and (for static sites) whole pages are served straight from the edge.
- Anything else is fetched from your server. Cloudflare forwards the request, gets the answer and passes it back to the visitor.
Because visitors never see your server’s real address, it’s much harder to attack directly.
Why We Use Cloudflare#
- 🛡️ Protection by default: firewall rules, bot protection and DDoS protection in front of every site, without extra plugins.
- 🚀 Faster sites: visitors load content from a nearby data centre rather than a single server.
- 💪 Handles traffic spikes: a mention on the news or a big promotion is absorbed by Cloudflare’s network instead of overloading your server.
- 🔒 SSL everywhere: certificates issued and renewed automatically.
- 🌐 Fast, reliable DNS with changes that take effect quickly.
- 🧰 One place to manage it all: security, caching, redirects and DNS in one dashboard, so problems are quicker to find.
Some sites we host, including our own website and these docs, run entirely on Cloudflare using Cloudflare Workers, with no traditional server at all.
Cloudflare vs No CDN#
| Feature | With Cloudflare | Without Cloudflare |
|---|---|---|
| Server address | Hidden behind Cloudflare | Visible to anyone |
| DDoS protection | Built in | Depends on your host |
| Bot and attack filtering | Filtered before reaching your site | Your site handles everything |
| Speed for distant visitors | Served from a nearby data centre | Every request travels to one server |
| Traffic spikes | Absorbed by the network | Can overload the server |
| SSL certificates | Automatic | Managed separately |
What You Might Notice#
Most of the time, Cloudflare is invisible. Occasionally you might see:
- A security check page (“Verify you are human”): see Why Am I Seeing a Cloudflare Check Page?
- A Turnstile checkbox on a form: see Cloudflare Turnstile
- A Cloudflare error page with a number like 522 or 1020: see Cloudflare Error Codes
- Cloudflare in your DNS settings: your domain’s nameservers point to Cloudflare, so DNS records are managed there. See DNS Record Types.
Common Questions#
Does Cloudflare see my website’s data? Cloudflare processes the traffic to your site so it can secure and speed it up, like any CDN or hosting provider. It’s an established provider with published privacy commitments.
Does Cloudflare affect my email? No. Email records (MX, SPF, DKIM and DMARC) live in DNS on Cloudflare, but email itself doesn’t pass through Cloudflare’s proxy.
What happens if Cloudflare has an outage? Cloudflare is built to keep working even when individual data centres have problems. Rare wider outages do happen, and they make the news because so much of the internet relies on Cloudflare.
Can my site be hosted somewhere other than Cloudflare and still use it? Yes. Cloudflare can sit in front of almost any host, including WordPress hosting, a VPS or Nextcloud.