What is WHMCS?
WHMCS (Web Host Manager Complete Solution) is a billing and client management platform for hosting resellers. It automates invoicing, payments, support tickets, and crucially, hosting account creation and management through DirectAdmin integration.
If you have 0724 Hosting reseller hosting, you can connect WHMCS to DirectAdmin to:
- Automatically create hosting accounts when customers order
- Suspend accounts when invoices become overdue
- Terminate accounts when subscriptions are cancelled
- Allow customers to log in to DirectAdmin directly from WHMCS
- Upgrade or downgrade hosting packages automatically
Prerequisites
Before connecting WHMCS to DirectAdmin, ensure you have:
- A reseller hosting account with 0724 Hosting
- WHMCS installed and accessible (you can install WHMCS via Softaculous in DirectAdmin)
- Your reseller DirectAdmin username and password (provided in your welcome email)
- Server hostname (e.g.,
server.0724.co.za) - Admin access to WHMCS
Step 1: Generate a DirectAdmin login key
For security, WHMCS should use a login key instead of your password to connect to DirectAdmin.
- Log in to your reseller DirectAdmin account
- Go to Account Manager β Login Keys
- Click Create Login Key
- Enter a name for the key (e.g., "WHMCS Integration")
- Set key expiry (select "Never" for permanent key or set a future date)
- Click Create
- Copy the generated login key and save it securely
Important: Store the login key safely. You will not be able to view it again after leaving this page.
Step 2: Add DirectAdmin server in WHMCS
Access server configuration
- Log in to WHMCS admin area
- Go to Setup β Products/Services β Servers
- Click Add New Server
Configure server settings
Fill in the following details:
Basic settings
- Name: A descriptive name for this server (e.g., "0724 Hosting Server 1")
- Hostname: Your server hostname without http:// or port (e.g.,
server.0724.co.za) - IP Address: Your server IP address (optional, hostname is sufficient)
- Assigned IP Address: Leave blank (used for dedicated IPs)
- Type: Select DirectAdmin from the dropdown
- Active: Check this box to enable the server
Server details
- Username: Your reseller DirectAdmin username (e.g.,
resellerusername) - Password: Leave blank if using login key
- Access Hash (Login Key): Paste your DirectAdmin login key here
- Secure: Check this box if your server uses SSL (port 2222 with https)
- Port Number: DirectAdmin port (usually
2222)
Status address
- Status Address: URL to check server status (optional)
- Nameserver 1:
ns1.0724.co.za - Nameserver 2:
ns2.0724.co.za - Nameserver 3, 4, 5: Leave blank
Test connection
- After filling in all details, click Test Connection
- WHMCS will attempt to connect to DirectAdmin
- If successful, you will see "Connection Successful"
- If it fails, verify your hostname, username, and login key are correct
Save configuration
- Once the connection test passes, click Save Changes
- The server is now configured and ready to provision accounts
Step 3: Create hosting products linked to DirectAdmin
Now that WHMCS can connect to DirectAdmin, create hosting products that use this server.
Create a new product
- In WHMCS, go to Setup β Products/Services β Products/Services
- Select an existing product group or click Create Group to make a new one (e.g., "Web Hosting")
- Click Create a New Product
Configure product details
General settings
- Product Type: Select Shared Hosting
- Product Name: Name your plan (e.g., "Basic Hosting")
- Product Group: Select the group you created
- Welcome Email: Select an email template (e.g., "Hosting Account Welcome Email")
Module settings
- Module Name: Select DirectAdmin
- Server Group: Leave as "None" unless using server groups
- Default Server: Select the DirectAdmin server you configured earlier
- Package Name: Enter the package name as it appears in DirectAdmin (e.g.,
package_basic)
Important: The package name must exactly match a hosting package configured in your reseller DirectAdmin account. To view packages, log in to DirectAdmin β Account Manager β Manage User Packages.
Additional DirectAdmin options
- Username Prefix: Optional prefix for usernames (leave blank for customer-chosen usernames)
- Username Generation: Choose how usernames are generated (random, email-based, or customer-chosen)
Configure pricing
- Go to the Pricing tab
- Set up pricing for monthly, quarterly, semi-annual, annual, etc.
- Mark the product as Active when ready to sell
- Click Save Changes
Step 4: Test account provisioning
Before going live, test that WHMCS can create hosting accounts in DirectAdmin:
- Place a test order in WHMCS (you can mark invoices as paid manually for testing)
- Go to Clients β View/Search Clients
- Find your test client and view their services
- Click the hosting service
- Click Create to manually provision the account (or wait for automatic provisioning after invoice payment)
- WHMCS will contact DirectAdmin and create the account
- Verify the account was created by logging in to DirectAdmin β Account Manager β List Accounts
Configuring DirectAdmin packages in reseller account
Before WHMCS can provision accounts, you must create hosting packages in your reseller DirectAdmin:
- Log in to your reseller DirectAdmin account
- Go to Account Manager β Manage User Packages
- Click Add Package
- Configure the package:
- Package Name: e.g.,
package_basic(must match WHMCS product configuration) - Bandwidth: Monthly bandwidth limit (e.g., 10GB, unlimited)
- Disk Space: Storage limit (e.g., 5GB, unlimited)
- Inodes: File count limit (recommended: 250,000)
- Domains: Number of addon domains allowed
- Subdomains: Number of subdomains (typically unlimited)
- Email Accounts: Maximum email accounts
- MySQL Databases: Number of databases allowed
- FTP Accounts: FTP accounts limit
- SSH Access: Enable or disable SSH/shell access
- PHP Settings: PHP version and settings
- Package Name: e.g.,
- Click Add to save the package
- Repeat for each hosting plan you want to offer (basic, business, advanced, etc.)
Automated account actions
Once connected, WHMCS will automatically handle these actions:
Account creation
- When a customer pays for a hosting order, WHMCS automatically creates the DirectAdmin account
- The customer receives a welcome email with login details
- The customer can log in to DirectAdmin from the WHMCS client area
Account suspension
- When an invoice becomes overdue (configurable grace period), WHMCS suspends the DirectAdmin account
- Suspended accounts cannot access DirectAdmin or their website
- Accounts are unsuspended automatically when the invoice is paid
Account termination
- When a service is cancelled or terminated, WHMCS deletes the DirectAdmin account
- All files, databases, and email accounts are permanently removed
Account upgrades/downgrades
- When a customer upgrades or downgrades their hosting plan, WHMCS changes the package in DirectAdmin
- Resources are adjusted automatically based on the new package limits
Troubleshooting connection issues
Connection test fails
If WHMCS cannot connect to DirectAdmin:
- Verify the hostname is correct (use server hostname, not your domain)
- Check that port 2222 is correct
- Ensure you are using your reseller username, not an end-user account
- Verify the login key is copied correctly (no extra spaces or line breaks)
- Ensure "Secure" is checked if using HTTPS/SSL
- Check that your server firewall allows connections from your WHMCS server IP
- Contact 0724 Hosting support to verify your reseller account has API access enabled
Accounts not being created automatically
If WHMCS is not provisioning accounts:
- Verify Auto Setup is enabled for the product (Setup β Products/Services β Edit Product β Module Settings)
- Check that the invoice was marked as paid
- Ensure the package name in WHMCS exactly matches a package in DirectAdmin
- Check WHMCS module logs: Utilities β Logs β Module Log
- Manually provision an account to see the specific error message
"Package does not exist" error
If you see this error during provisioning:
- The package name in WHMCS does not match any package in DirectAdmin
- Log in to DirectAdmin β Manage User Packages and verify package names
- Update the package name in WHMCS product configuration to match exactly
- Package names are case-sensitive
Customers cannot log in to DirectAdmin from WHMCS
If the DirectAdmin login button in WHMCS does not work:
- Verify the account was created successfully in DirectAdmin
- Check that the server configuration is marked as Active
- Ensure the login key has not expired
- Clear WHMCS template cache: Utilities β System β Template Cache
Best practices for WHMCS-DirectAdmin integration
- Use login keys: Always use DirectAdmin login keys instead of passwords for better security
- Test before going live: Create test orders and verify provisioning works correctly
- Match package names exactly: Ensure WHMCS product package names match DirectAdmin packages precisely
- Configure auto-suspension: Set appropriate overdue grace periods in WHMCS
- Set up email templates: Customise welcome emails with your branding and DirectAdmin login instructions
- Monitor module logs: Regularly check WHMCS module logs for provisioning errors
- Backup DirectAdmin packages: Keep a record of your package configurations in case you need to recreate them
- Secure your WHMCS installation: Use SSL, strong admin passwords, and enable two-factor authentication
Advanced configuration
Using server groups
If you manage multiple DirectAdmin servers, use server groups to distribute accounts:
- Add multiple DirectAdmin servers to WHMCS
- Create a server group: Setup β Products/Services β Servers β Server Groups
- Add your DirectAdmin servers to the group
- In product configuration, select the server group instead of a specific server
- WHMCS will automatically provision accounts to the server with the least accounts
Configurable options
Allow customers to customise their hosting during checkout:
- Go to Setup β Products/Services β Configurable Options
- Create option groups for extras (e.g., additional disk space, extra email accounts, SSL certificates)
- Assign the option group to your hosting products
- Customers can select these options during order, adjusting their plan
Getting help with WHMCS integration
If you need assistance setting up WHMCS, connecting to DirectAdmin, troubleshooting provisioning issues, or configuring hosting packages, contact 0724 Hosting support. We can help with:
- Generating and configuring DirectAdmin login keys
- Troubleshooting WHMCS-DirectAdmin connection issues
- Creating and configuring hosting packages
- Setting up automation rules and email templates
- Resolving account provisioning errors
We also provide WHMCS installation and setup assistance for reseller hosting clients.