Skip to main content

How to Create a WHM API Token for the Root Account

You can create a WHM API token to allow external applications or scripts to interact with the WHM interface on behalf of the root account. This method provides a secure way to perform administrative tasks without sharing the primary root password.

You can create a WHM API token to allow external applications or scripts to interact with the WHM interface on behalf of the root account. This method provides a secure way to perform administrative tasks without sharing the primary root password.

Before you begin

You will need:

  • Root access to the WHM interface

  • A specific use case for the API (such as a third-party integration or custom script)

Create the API token

  1. Log in to WHM.

  2. In the left-hand navigation menu, go to Tools > Server Configuration > Manage API Tokens.

  3. Click the Add New Token button.

  4. Enter a descriptive name for the token in the Token Name field.

  5. Select the Root account from the Account dropdown menu.

  6. Click Add.

Confirm the result

Once the token is created, the system will display the token's details.

  • The token will appear in the list of active tokens.

  • The system will display the token's unique value.

Important: You must copy and save the token value immediately. For security reasons, the full token value will not be displayed again once you leave this page.

Limitations

The token is tied specifically to the root account. If the root account's permissions are restricted or if the token is deleted, any automated processes using that specific token will stop functioning.

Did this answer your question?