Skip to content
Cloudflare for Teams
Visit Cloudflare for Teams on GitHub
Set theme to dark (⇧+D)

Authenticate cloudflared

Before you start
1. Add a website to Cloudflare
2. Change your domain nameservers to Cloudflare
3. Install cloudflared

Follow these steps to authenticate cloudflared:

  1. Log in to your Cloudflare account with the following command:

    $ cloudflared tunnel login
  2. The command will attempt to open a browser window and prompt you to authenticate with your Cloudflare account.

    If running on a headless system, copy the link and paste it into a browser.

  3. Choose any hostname in your account. Cloudflare will issue credentials that are account-wide in scope; you do not need to pick a specific hostname where you plan to connect the Tunnel.

  4. Once authenticated, Cloudflare will return a certificate file, cert.pem, that will give this instance of cloudflared the ability to:

    • Create and delete Tunnels
    • Modify DNS records in your account

    The file is required if you want to:

    • Create new Tunnels
    • Configure routing from cloudflared

    The file is not required if you want to:

    • Run an existing Tunnel
    • Manage routing from the Cloudflare dashboard