Create subdomain in DirectAdmin
A subdomain is a separate section of your main domain that you can use for specific purposes. In this guide, we explain how to create subdomains in DirectAdmin.
What is a subdomain?
A subdomain is a prefix to your main domain that points to a separate section of your website. Examples:
- blog.yoursite.com - for your blog
- shop.yoursite.com - for your webshop
- support.yoursite.com - for your helpdesk
- staging.yoursite.com - for test versions
Benefits of subdomains
- Organization: Keep different sections separate
- SEO: Subdomains can rank separately in Google
- Separate installations: Install WordPress, Magento or other software separately
- Security: Isolate sensitive sections
- Testing: Create staging environments without affecting production
Subdomain vs. Subfolder
| Feature | Subdomain | Subfolder |
|---|---|---|
| URL | blog.site.com | site.com/blog |
| SEO | Separate website | Part of main site |
| Installation | Own root folder | Within public_html |
| SSL | Own certificate | Same as main site |
Creating a subdomain
Step 1: Log in to DirectAdmin
- Go to Theory7's DirectAdmin login portal
- Enter your username and password
- Click Login
Step 2: Navigate to Subdomain Management
- Find Domain Setup or Subdomain Management in the menu
- Click on Subdomains
- You'll see an overview of existing subdomains
Step 3: Create new subdomain
- Click Create Subdomain
- Enter the subdomain name (e.g.,
blog,shop,test) - Select the main domain if you have multiple
- Click Create
Step 4: Configure subdomain
After creation, a folder is automatically created:
- Location:
/domains/yourdomain.com/public_html/blog(for subdomain blog) - Or:
/domains/blog.yourdomain.com/public_html(as separate domain)
Managing subdomains
Upload content
- Connect via FTP to your server
- Navigate to the subdomain folder
- Upload your files (index.html, WordPress, etc.)
Delete subdomain
- Go to Subdomain Management
- Find the subdomain in the list
- Click Delete
- Confirm the action
Note: Deleting also removes all files in the folder!
Redirect subdomain
You can redirect a subdomain to another URL:
- Go to Subdomain Management
- Click on the subdomain
- Choose Redirect
- Enter the target URL
- Click Save
Installing WordPress on subdomain
Via Installatron
- Go to Installatron in DirectAdmin
- Search for WordPress
- Click Install
- At Domain select your subdomain
- Follow the installation wizard
Manually
- Download WordPress from wordpress.org
- Upload to the subdomain folder via FTP
- Create a database in DirectAdmin
- Open the subdomain in your browser
- Follow the WordPress installation
SSL for subdomains
Let's Encrypt SSL
- Go to SSL Certificates in DirectAdmin
- Click Free & automatic certificate from Let's Encrypt
- Check your subdomain
- Click Save
Wildcard SSL
A wildcard SSL (*.yourdomain.com) automatically covers all subdomains. Contact support for configuration.
DNS settings
Subdomains automatically get the correct DNS records. Check in DNS Zone Editor:
blog A 123.45.67.89 (same IP as main domain)
shop A 123.45.67.89
External subdomain
Want to point a subdomain to an external service?
- Go to DNS Zone Editor
- Add an A or CNAME record:
- A record:
extern A 98.76.54.32(external IP) - CNAME:
extern CNAME example.com.(external domain name)
- A record:
Common problems
Subdomain shows main site
- Check if the subdomain folder exists
- Verify there's an index.html or index.php in it
- Wait for DNS propagation (up to 24 hours)
Cannot create subdomain
- Check if the subdomain name is valid (only letters, numbers, hyphens)
- Verify the subdomain doesn't already exist
- Check your account limits
SSL not working on subdomain
- Request a separate SSL certificate
- Or configure a wildcard certificate
- Wait 15-30 minutes after request
Tips for subdomains
- Short names: Use short, clear names (blog, shop, app)
- Consistent: Keep naming consistent across all projects
- Backup: Make backups before modifying subdomains
- Don't forget SSL: Each subdomain needs SSL
- Use staging: Test changes first on a staging subdomain
Need help?
We're here for you! Running into issues or have questions? Our support team is happy to help you personally. Drop us a message through the ticket system - we usually respond within a few hours and love helping you find the best solution.
0 van 0 vonden dit nuttig