☁️ How to Connect a Domain to Cloudflare: Step-by-Step Guide
Cloudflare is one of the most popular services for website protection, DNS management, and performance optimization. By connecting your domain to Cloudflare, you get a free CDN, DDoS protection, automatic HTTPS, HTTP/3 support, traffic filtering, and a user-friendly DNS panel. Here's a 5-step guide to help you connect your domain.
🔧 Step 1: Sign up or Log in to Cloudflare
- 🌐 Visit dash.cloudflare.com
- 📥 Sign up or log in to your existing account
- ➕ Click “Add a Site”
- 📝 Enter your domain name (e.g.,
example.com
) and click “Continue”
📦 Step 2: Choose a Plan (Free is Available)
Cloudflare offers several plans. Select the Free plan if you don’t need advanced features like Web Application Firewall (WAF) or network prioritization.
🧭 Step 3: Import and Configure DNS Records
- 🔍 Cloudflare will try to automatically detect your current DNS records
- ➕ Check A records (e.g.,
@
andwww
) — they should point to your VPS IP - ✍️ If A records are missing, add them manually:
Type: A Name: @ Value: YOUR_SERVER_IP TTL: Auto Proxy status: 🟠 Proxied
Type: A Name: www Value: YOUR_SERVER_IP TTL: Auto Proxy status: 🟠 Proxied
- 🟠 Make sure proxying is enabled to activate protection and caching
- 🛠 If you're using email, also configure MX and TXT records properly
🔄 Step 4: Change Nameservers at Your Registrar
After adding your domain, Cloudflare will show two nameservers, for example:
emily.ns.cloudflare.com matt.ns.cloudflare.com
Go to your domain registrar’s control panel and replace your current NS records with the Cloudflare ones. Changes usually propagate within 5–24 hours.
🔒 Step 5: Enable HTTPS and Security Settings
- 🔐 Go to the SSL/TLS tab and select Full or Flexible mode
- 🧷 In the “Edge Certificates” section, enable “Always Use HTTPS”
- 🛡 Enable “Auto Minify” and “Brotli” in the “Speed” section
- ⚙ Configure bot protection and country restrictions if needed
📌 Tips from Bit.Hosting
- 📥 Regularly review your DNS records, especially after changing hosting
- 🔐 Use “Full” SSL mode for secure HTTPS with a valid server certificate
- 🕒 Wait for full DNS propagation after nameserver changes
- 🔄 Use cache smartly — some control panels may require proxy to be disabled
- 📊 Use Cloudflare analytics to monitor traffic and block threats
If you're unsure how to connect your domain or having delegation issues — contact our support team. We’ll help you set everything up! ⚙️