Page tree
Skip to end of metadata
Go to start of metadata


This document lists all restrictions on cPanel & WHM usernames.

Basic restrictions

The following list describes a basic set of rules to follow when you create a username:

  • Only uses the a-z, 0-9, or '.' characters.


    We strongly recommend that you do not use a period in the username because it may cause conflicts in MySQL®.

  • 16 characters or fewer.
  • Cannot begin with a digit (0-9) or a period (.)
  • Cannot start with the characters test
  • Cannot end with the characters assword

Special cases

  • You cannot create a username with the hyphen character (-), but you can change an account's name to use a hyphen when you transfer that account to another system.
  • If you wish to allow usernames over eight characters in length, set the LONGUSERS: 1 environment variable in the /var/cpanel/whm/nvdata/root.yaml file.
  • If you plan to use MySQL or PostgreSQL as a database engine, the first eight characters must be unique on the system.


    You can disable database prefixing with the Add prefix to names of new databases and database users option in the SQL section of WHM's Tweak Settings interface (WHM >> Home >> Server Configuration >> Tweak Settings).

  • If you wish to allow leading digits in a username, create the /etc/allowstupidstuff touchfile.

Reserved names and restricted aliases

cPanel & WHM checks the following files to determine whether to reserve or restrict a username or alias:

  • /usr/local/cpanel/Cpanel/Validate/Username/
  • /etc/aliases
  • /etc/localaliases

Additional documentation