< All Topics

Setting Up Cloudflare

Already have a Cloudflare account? If so, skip down to ‘Create an access token’

1. Create a Cloudflare account

  • Visit: https://www.cloudflare.com/
  • Click on ‘Sign Up’ and follow the steps to create your account

2. Create an access token

  • Go to your profile settings in the Cloudflare dashboard (icon at the top right of the screen)
  • Click on the ‘API Tokens’ tab
  • Click ‘Create Token’
  • Click on ‘Use template’ next to the ‘Edit zone DNS’ option (this gives you the permissions to edit an existing zone and takes you to the ‘Create Token’ page.
  • Add an extra permission to automatically create zones by clicking on ‘Add more’ (under Permissions), and select ‘Zone’ -> ‘Zone’ -> ‘Edit’
  • Under ‘Zone Resources’, make sure you set ‘Include’ -> ‘All zones’ (unless you only want to allow some of your domains to be managed, in which case you can customize this as required.
  • For extra security, if you would like to restrict this token to only allow requests from your server, you may like to activate IP Address Filtering by selecting the appropriate options. Note that Cloudflare seems to connect via IPv6 addresses by default (assuming they are available for your server), so if you have an IPv6 address, put this in here, as well as your IPv4 address if you like.
  • Click on ‘Continue to summary’
  • The summary should show that a token is being created for “All zones – DNS:Edit, Zone:Edit
  • Click on ‘Create Token’
  • You should get the message that the DNS API token was successfully created. Make note of this token, or copy it ready to paste into daflare – NOTE: this is the only time you get shown this token. If you do happen to forget to write it down, you are able to ‘roll’ the token and get a new one.

3. Find your assigned Cloudflare nameservers

Cloudflare will assign your account two nameservers from a list of about 30 available nameserver names. You will need to know your assigned nameservers to update your domain at your domain registrar, and to assign as your nameservers when editing your domain in DirectAdmin.

You’re new to Cloudflare

If you’re new to Cloudflare, you’ll need to manually add one domain to Cloudflare to find out what your assigned nameserver names are.

  • Login to your Cloudflare account
  • Go to your dashboard and click on ‘Add site’
  • Enter your domain name and click ‘Add site’
  • If you haven’t already selected a plan, select a Cloudflare plan (note that the free plan works perfectly with this plugin, but you may want to consider the other options)
  • Your existing DNS records will be transferred across to Cloudflare. Click ‘Continue’
  • The next page will display your assigned Cloudflare nameservers. Make a note of these nameservers

You’re an existing Cloudflare customer

  • Login to your Cloudflare account
  • Click on one of your existing domains
  • Click on DNS
  • Scroll down the page to view your Cloudflare nameservers. These are the nameservers that are used for all domains within your account

Previous Initial Configuration – Important!
Next Software License
Table of Contents