Skip to content
BeoHosting
BeoHosting
Hosting

What Is Cloudflare and How to Use It

BeoHosting Team··10 min read read
What Is Cloudflare and How to Use It

Cloudflare is one of the best-known companies in internet infrastructure. It is useful as a complement to your hosting plan. It is used by over 20% of all sites on the internet, including many large companies. In this guide we explain what Cloudflare actually does, why you would use it, and how to set it up for your site.

What is Cloudflare?

Cloudflare is a company that provides CDN (Content Delivery Network), DNS, DDoS protection, and web security services. In essence, Cloudflare sits between your site and visitors, filtering traffic, blocking attacks, and accelerating content delivery.

Think of Cloudflare as a security guard in front of your site checking everyone who tries to enter. Legitimate visitors are let through quickly, while malicious ones are blocked before reaching your server.

CDN - Content Delivery Network

A CDN is a network of servers distributed around the world that stores copies of your site. For basic security, encrypted communication with the visitor is mandatory (images, CSS, JavaScript files) at locations close to your visitors. When someone from New York visits your site hosted in a US data center, instead of data traveling across the Atlantic, Cloudflare delivers it from the closest server in the US.

CDN benefits:

Faster page loading because content is delivered from the nearest location. Cloudflare has more than 310 data centers in over 120 countries, so it is always close to your visitors.

Less load on your server because Cloudflare caches static files and serves them without sending the request to your server. This means your server handles fewer requests and can support more concurrent visitors.

Bandwidth savings because static content is delivered from the Cloudflare network rather than your hosting. This can significantly reduce traffic usage on your hosting plan.

DDoS protection

A DDoS (Distributed Denial of Service) attack tries to take your site down by flooding it with massive traffic. Attackers use thousands or millions of compromised machines (a botnet) to send requests to your server simultaneously until it crashes.

Cloudflare automatically detects and blocks DDoS attacks without any configuration on your side. Their network can absorb attacks of hundreds of gigabits per second - far more than any single server can handle.

Even on the free plan, Cloudflare provides unlimited DDoS protection. This is one of the most valuable features, since professional DDoS protection from other providers can cost hundreds of dollars a month.

DNS management

Cloudflare provides free DNS hosting that is one of the fastest in the world. DNS is the system that translates a domain name (e.g. beohosting.com) to a server IP address. Faster DNS means faster initial site load.

Cloudflare DNS supports all standard record types (A, AAAA, CNAME, MX, TXT, etc.) and provides an intuitive management interface. Propagation of DNS changes is almost instant, unlike some DNS providers where it can take hours.

An important feature is "proxy" mode - the orange cloud icon. When proxy is on, traffic passes through the Cloudflare network and your site gets CDN, DDoS protection, and other benefits. When off (gray cloud), DNS just points to your server without any extra services.

SSL/TLS certificates

Cloudflare automatically issues a free SSL certificate for your domain. You have several SSL mode options:

Flexible: Encrypts the connection between the visitor and Cloudflare, but not between Cloudflare and your server. Not recommended for sites with sensitive data.

Full: Encrypts the entire connection, but Cloudflare does not validate the SSL certificate on your server.

Full (Strict): The recommended mode. Encrypts the entire connection and requires a valid SSL certificate on your server. BeoHosting plans include a free SSL certificate, so you can use Full (Strict) without any issues.

Free vs paid plans

Free plan: Includes CDN, unlimited DDoS protection, free SSL, DNS hosting, basic firewall rules (up to 5), and Page Rules (up to 3). This is enough for most small and medium sites.

Pro plan ($20/month): Adds WAF (Web Application Firewall), advanced image optimization (Polish, Mirage), mobile optimization, and better caching. A good fit for business sites with higher traffic.

Business plan ($200/month): Advanced WAF features, custom SSL certificates, 100% uptime SLA, and priority support. For serious business sites.

Enterprise plan (custom pricing): Fully customizable, dedicated account manager, advanced analytics, and an SLA with financial guarantee. For large companies and sites with millions of visitors.

How to set up Cloudflare - step by step

Step 1: Sign up at cloudflare.com. A free account is enough to start.

Step 2: Click "Add a Site" and enter your domain (e.g. yourcompany.com). Cloudflare will automatically scan existing DNS records.

Step 3: Review the DNS records Cloudflare found. Verify everything is correct - especially the A record pointing to your server's IP address and MX records for email.

Step 4: Cloudflare gives you two nameservers (e.g. anna.ns.cloudflare.com and bob.ns.cloudflare.com). Go to your domain registrar and change the nameservers to these Cloudflare nameservers.

Step 5: Wait for DNS to propagate (usually 1-24 hours, often faster). Cloudflare will email you when activation is complete.

Step 6: Set SSL mode to "Full (Strict)" if you have an SSL certificate on the server (BeoHosting plans do). Enable "Always Use HTTPS" and "Automatic HTTPS Rewrites".

Common settings after activation

Page Rules: On the free plan you have 3 Page Rules. We recommend: Cache Level: Cache Everything for static pages, Browser Cache TTL to control browser caching, and a Forwarding Rule to redirect www to non-www (or vice versa).

Firewall Rules: Block access to wp-admin from countries you do not expect traffic from. This drastically reduces brute-force attacks on WordPress login.

Speed optimization: Enable Auto Minify for HTML, CSS, and JavaScript. Enable Brotli compression for even smaller files. On the Pro plan, Polish automatically optimizes images.

Under Attack Mode: If you notice an attack on your site, enable "I'm Under Attack" mode. Cloudflare will show a challenge page to every visitor before letting them through. Use this only during an active attack, as it slows legitimate visitors.

Potential issues and fixes

Email not working: MX records MUST NOT be proxied (orange cloud). If you have email on the domain, make sure MX records are in "DNS only" mode (gray cloud).

Redirect loop: This happens when SSL mode is set to "Flexible" while your server forces HTTPS. Change SSL mode to "Full" or "Full (Strict)".

Old content: Cloudflare caches your site. If you made changes but do not see them, purge the Cloudflare cache: Caching > Purge Everything. You can also purge individual URLs.

WordPress admin issues: Some WordPress plugins (especially security ones) may have trouble with the Cloudflare proxy because they see the Cloudflare IP instead of the real visitor IP. Install the official Cloudflare WordPress plugin, which resolves this.

Conclusion

Cloudflare is a powerful, mostly free tool that can significantly improve the speed, security, and reliability of your site. The free plan is more than enough for most sites, and setup takes only 15-20 minutes. By combining Cloudflare with quality hosting like BeoHosting, your site gets CDN speed, DDoS protection, and an SSL certificate at no extra cost. We recommend everyone at least try Cloudflare - there is no reason not to use something that is free and so useful.

BeoHosting Team

10+ years of experience — Web hosting and infrastructure specialists

  • Web Hosting
  • WordPress Hosting
  • VPS
  • Dedicated Serveri
  • Domeni
  • SSL
  • cPanel
  • LiteSpeed
  • Linux administracija
  • DNS

Last updated: