Setting up a Domain on Cloudflare

Adding a CNAME Record

  1. Log in to your Cloudflare dashboard.
  2. Select the domain you want to configure.
  3. Click DNS in the left sidebar, then Records.
  4. Click Add Record.
  5. In the Type dropdown, select CNAME.
  6. In the Name field, enter: www
  7. In the Target field, enter your IndieMade URL (e.g., yourshop.indiemade.com).
  8. Set the Proxy status toggle based on your preference - “DNS only” (gray cloud) passes traffic directly, while “Proxied” (orange cloud) routes traffic through Cloudflare.
  9. Click Save.
Important: If you plan to use Cloudflare’s redirect rules (see below), the DNS record for the root domain must be proxied (orange cloud enabled). Redirects only work for proxied hostnames.

Setting Up Domain Forwarding with Redirect Rules

To redirect your root domain (yourdomain.com) to www.yourdomain.com, use Cloudflare Redirect Rules.

Step 1: Add a Root Domain DNS Record

You need a DNS record for the root domain so Cloudflare can process the redirect. Add an A record:

  • Type: A
  • Name: @
  • Content: 192.0.2.1 (this is a placeholder - traffic will be redirected before reaching this address)
  • Proxy status: Proxied (orange cloud - required for redirects to work)

Step 2: Create a Redirect Rule

  1. In the Cloudflare dashboard, select your domain.
  2. Go to Rules in the left sidebar, then Redirect Rules.
  3. Click Create Rule.
  4. Give the rule a name (e.g., “Root to www redirect”).
  5. Under When incoming requests match, choose Wildcard pattern and enter: https://yourdomain.com/*
  6. Under URL redirect:
    • Target URL: https://www.yourdomain.com/${1}
    • Status code: 301
    • Check Preserve query string
  7. Click Deploy.

The ${1} in the target URL captures anything after the root domain, so all paths are preserved in the redirect (e.g., yourdomain.com/shop redirects to www.yourdomain.com/shop).