Cloudflare Email Routing is a powerful, free tool that lets you create custom email addresses for your domain and route them directly to target destinations. If you are building a custom email platform or just want to organize your domain, here is how to set it up perfectly.

Step 1: Activate Email Routing in Cloudflare

Log in to your Cloudflare dashboard, select your active domain, and navigate to the **Email** section on the left sidebar. Click on **Email Routing** and select **Get Started**.

Step 2: Set Up Destination Addresses

Before routing messages, you must specify a destination email address (like your personal Gmail account) where Cloudflare can forward verified messages. Cloudflare will send a verification link to this destination address. You must click it to authorize forwarding.

Step 3: Configure Routing Rules

You can create two types of routing rules:

  • Custom Addresses: Map a specific address, like info@yourdomain.com, to your destination address.
  • Catch-All: Route any email prefix to your destination. This is crucial if you want to support unlimited random addresses.

Step 4: Update DNS Records Automatically

Cloudflare will detect if your MX and SPF records are configured correctly. Click the "Add records automatically" button to have Cloudflare replace existing mail records with their secure, optimized routing servers. Your custom domain is now ready to receive emails anywhere!