To install a control panel on a VPS, pick a supported Linux OS, update the server, set an FQDN hostname, and run the vendor’s installer: cPanel (sh latest), Plesk (one-click installer), or DirectAdmin (setup.sh).
Open required ports, finish the web-based setup, then add domains, SSL, email, and backups. If you’re wondering how to install a control panel on VPS, this guide walks you step by step through cPanel, Plesk, and DirectAdmin.
I’ll cover requirements, commands, firewall ports, post-install hardening, and practical tips gathered from 12+ years running production hosting stacks. You’ll be live with a secure, manageable server in under an hour.
What is a VPS Control Panel and Why Use One?

A VPS control panel is a web based interface to manage websites, DNS, SSL, email, databases, and server services without deep command line work.
Popular choices include cPanel/WHM, Plesk, and DirectAdmin. They streamline hosting tasks, standardize security, and cut admin time for agencies, freelancers, and businesses scaling multiple sites.
Quick Checklist (Do This Before Any Install)
Use this pre-install checklist to avoid 90% of common issues:
- Fresh VPS with root access and a supported 64-bit OS (no prior panel installed).
- Recommended resources: 2–4 GB RAM (cPanel 4 GB+ ideal), 2 vCPU+, 60 GB+ SSD, stable network.
- Set a Fully Qualified Domain Name (FQDN) for the server, e.g., server.example.com.
- Point an A record for the hostname to the VPS IP; consider configuring reverse DNS (PTR).
- System updated and time synced (NTP/chrony); swap configured if RAM is low.
- Firewall ready: open panel-specific ports and standard web/mail/DNS ports.
- License ready (Plesk/DirectAdmin can be trialed; cPanel needs a license after install).
System Preparation (All Panels)
Run these baseline steps on a clean server. Replace variables in ALL_CAPS with your values.
# 1) Connect as root
ssh root@YOUR_SERVER_IP
# 2) Update OS
# AlmaLinux/Rocky
dnf -y update
# Ubuntu/Debian
apt update && apt -y upgrade
# 3) Set FQDN hostname
hostnamectl set-hostname server.example.com
# 4) Ensure /etc/hosts maps hostname to IP
echo "YOUR_SERVER_IP server.example.com server" >> /etc/hosts
# 5) Optional: add 2G swap if RAM is low
fallocate -l 2G /swapfile || dd if=/dev/zero of=/swapfile bs=1M count=2048
chmod 600 /swapfile
mkswap /swapfile
swapon /swapfile
echo "/swapfile none swap sw 0 0" >> /etc/fstab
Install cPanel/WHM on VPS (AlmaLinux/Rocky)
cPanel/WHM is the hosting industry standard for multi-account management. It supports AlmaLinux 8/9 and Rocky Linux 8/9 on fresh servers.
Requirements and Notes
- OS: AlmaLinux/Rocky 8 or 9 (fresh install, minimal profile recommended).
- Memory: 4 GB+ recommended; Storage: 60 GB+ SSD; IPv4 required.
- License: purchase/activate after install. Trial may be auto-detected.
- Do not install on Ubuntu/Debian (not supported).
Installation Commands
# cPanel/WHM install
dnf -y install perl curl
cd /home
curl -o latest -L https://securedownloads.cpanel.net/latest
sh latest
# Installation can take 30–60 minutes. Don't interrupt.
Open Required Firewall Ports (firewalld)
# Core cPanel/WHM and common services
firewall-cmd --permanent --add-port=2087/tcp # WHM (SSL)
firewall-cmd --permanent --add-port=2083/tcp # cPanel (SSL)
firewall-cmd --permanent --add-port=80/tcp # HTTP
firewall-cmd --permanent --add-port=443/tcp # HTTPS
firewall-cmd --permanent --add-port=53/udp # DNS
firewall-cmd --permanent --add-port=53/tcp # DNS
firewall-cmd --permanent --add-port=25/tcp # SMTP
firewall-cmd --permanent --add-port=465/tcp # SMTPS
firewall-cmd --permanent --add-port=587/tcp # Submission
firewall-cmd --permanent --add-port=110/tcp # POP3
firewall-cmd --permanent --add-port=995/tcp # POP3S
firewall-cmd --permanent --add-port=143/tcp # IMAP
firewall-cmd --permanent --add-port=993/tcp # IMAPS
firewall-cmd --permanent --add-port=21/tcp # FTP
firewall-cmd --reload
First Login and Setup
- Access WHM at: https://YOUR_SERVER_IP:2087 (user: root, password: your root password).
- Accept license, add contact email, configure nameservers (e.g., ns1/ns2.example.com).
- Enable AutoSSL (Let’s Encrypt/ZeroSSL) for free certificates.
- Create your first cPanel account and upload your site.
Install Plesk on VPS (Ubuntu/Debian/AlmaLinux/Rocky)
Plesk Obsidian runs on Ubuntu 22.04 LTS, Debian 11/12, AlmaLinux 8/9, and Rocky Linux 8/9. It’s popular with agencies and WordPress users thanks to WordPress Toolkit, Nginx caching, and robust security extensions.
Quick One Click Install
# For Ubuntu/Debian/AlmaLinux/Rocky (as root)
wget https://autoinstall.plesk.com/one-click-installer
chmod +x one-click-installer
./one-click-installer
# To choose components interactively:
./one-click-installer --all-versions
Open Required Firewall Ports
# firewalld example
firewall-cmd --permanent --add-port=8443/tcp # Plesk (HTTPS)
firewall-cmd --permanent --add-port=8447/tcp # Plesk Installer/Updates
firewall-cmd --permanent --add-port=8880/tcp # Plesk (HTTP)
firewall-cmd --permanent --add-port=80/tcp
firewall-cmd --permanent --add-port=443/tcp
firewall-cmd --permanent --add-port=53/udp
firewall-cmd --permanent --add-port=53/tcp
firewall-cmd --permanent --add-port=25/tcp
firewall-cmd --permanent --add-port=465/tcp
firewall-cmd --permanent --add-port=587/tcp
firewall-cmd --permanent --add-port=110/tcp
firewall-cmd --permanent --add-port=995/tcp
firewall-cmd --permanent --add-port=143/tcp
firewall-cmd --permanent --add-port=993/tcp
firewall-cmd --permanent --add-port=21/tcp
firewall-cmd --reload
First Login and Setup
- Access Plesk at: https://YOUR_SERVER_IP:8443 (Linux: user root; Ubuntu may use root, not sudo user).
- Set admin email/password, add a license (trial or purchased), and pick a hosting mode.
- Install extensions: Let’s Encrypt, Fail2ban, WordPress Toolkit, Advisor.
- Add your domain, enable HTTP/2, and issue SSL with Let’s Encrypt.
Install DirectAdmin on VPS (AlmaLinux/Debian/Ubuntu)
DirectAdmin is lightweight, fast, and cost-effective. Great for budget-conscious resellers and admins who prefer simplicity with full control.
Installation Commands
# Supported: AlmaLinux/Rocky 8/9, Debian 11/12, Ubuntu 20.04/22.04 LTS
# Have your DirectAdmin client ID and license ID ready
curl -O https://www.directadmin.com/setup.sh
chmod 755 setup.sh
./setup.sh auto
# Follow prompts (hostname, network device, services). Install takes ~20–40 minutes.
Open Required Firewall Ports
firewall-cmd --permanent --add-port=2222/tcp # DirectAdmin panel
firewall-cmd --permanent --add-port=80/tcp
firewall-cmd --permanent --add-port=443/tcp
firewall-cmd --permanent --add-port=53/udp
firewall-cmd --permanent --add-port=53/tcp
firewall-cmd --permanent --add-port=25/tcp
firewall-cmd --permanent --add-port=465/tcp
firewall-cmd --permanent --add-port=587/tcp
firewall-cmd --permanent --add-port=110/tcp
firewall-cmd --permanent --add-port=995/tcp
firewall-cmd --permanent --add-port=143/tcp
firewall-cmd --permanent --add-port=993/tcp
firewall-cmd --permanent --add-port=21/tcp
firewall-cmd --reload
First Login and Setup
- Access DirectAdmin at: https://YOUR_SERVER_IP:2222 (admin user created during setup).
- Apply your license if not added during install; configure nameservers and services.
- Install Let’s Encrypt certificates via the panel for domains and the server hostname.
DNS and Domain Configuration (Works for All Panels)
Two common approaches exist for DNS:
- Use panel DNS: Create ns1/ns2.example.com in the panel, then add glue records at your domain registrar pointing ns1/ns2 to your VPS IP(s). Set these nameservers for all hosted domains.
- Use external DNS (e.g., Cloudflare, Route 53): Keep DNS off the VPS, point A/AAAA/MX records to your server, and use CNAME flattening for apex if needed. This reduces load and simplifies migration.
For small setups, external DNS is often easier and more resilient. For reseller hosting with many zones, panel-based DNS plus secondary DNS is typical.
Post-Install Hardening and Optimization
- Enable SSL everywhere: AutoSSL (cPanel), Let’s Encrypt (Plesk/DirectAdmin) for both hostname and domains.
- Backups: Schedule daily incremental backups; sync to S3/Wasabi/remote FTP. Test restores monthly.
- Security: Enforce strong passwords, SSH keys, and 2FA where available. Install Fail2ban/CSF; limit password-auth SSH.
- PHP/HTTP performance: Use PHP-FPM and Opcache; enable HTTP/2; consider Brotli and Nginx proxy (Plesk/DirectAdmin) or NGINX Manager for cPanel.
- Monitoring: Set up alerts (load, disk, RAM), log rotation, and malware scans (Imunify360/ModSecurity rules).
- Updates: Keep OS and panel updated automatically in a maintenance window.
cPanel vs Plesk vs DirectAdmin: Which Should You Choose?
- cPanel/WHM: Best for classic multi-tenant hosting and resellers; massive ecosystem, predictable workflows. Linux (RHEL family) only.
- Plesk: Best for WordPress-heavy stacks and agencies; rich tooling and supports Linux. Simple Git/CD and Nginx caching options.
- DirectAdmin: Best for lean, fast, and affordable hosting; lower resource use; straightforward UI; excellent for budget VPS.
- Pricing: cPanel generally costs more per-account at scale; Plesk offers web admin/host editions; DirectAdmin is usually the most economical.
If you prefer a ready to go environment, YouStable offers managed VPS with cPanel, Plesk, or DirectAdmin preinstalled, licensed, security-hardened, and backed by 24×7 support and free migration. This lets you focus on websites, not server plumbing.
Common Errors and Quick Fixes
- Installer fails on non-FQDN hostname: Set a valid FQDN (hostnamectl) and ensure it resolves via /etc/hosts.
- License not detected: Ensure the VPS has a public IPv4 and outbound connectivity; verify license is bound to the correct IP.
- Ports blocked: Open the panel-specific and mail/web/DNS ports in firewalld or ufw; verify any upstream provider firewall.
- Low memory: Add swap; reduce services; on micro-VPS consider DirectAdmin for lower footprint.
- Not a fresh OS: Panels require a clean system; reinstall the OS if you tried multiple panels on the same VPS.
Example: UFW Rules on Ubuntu (Plesk/DirectAdmin)
ufw allow 22/tcp
# Plesk
ufw allow 8443/tcp
ufw allow 8447/tcp
# DirectAdmin
ufw allow 2222/tcp
# Common services
ufw allow 80/tcp
ufw allow 443/tcp
ufw allow 53
ufw allow 25/tcp
ufw allow 465/tcp
ufw allow 587/tcp
ufw allow 110/tcp
ufw allow 995/tcp
ufw allow 143/tcp
ufw allow 993/tcp
ufw allow 21/tcp
ufw enable
FAQ’s – Install a Control Panel on VPS
Can I install cPanel on Ubuntu?
No. cPanel/WHM supports RHEL derivatives like AlmaLinux and Rocky Linux (8/9). Use Plesk or DirectAdmin if you prefer Ubuntu/Debian.
How much RAM do I need for a VPS control panel?
Minimum 2 GB for testing, but 4 GB+ is recommended for production, especially with cPanel or multiple WordPress sites. Always add swap (2–4 GB) on small VPS plans.
Which is better: cPanel, Plesk, or DirectAdmin?
It depends on your stack and budget: cPanel for classic multi-account Linux hosting, Plesk for WordPress-centric and feature-rich management, DirectAdmin for lightweight, lower-cost setups. All are reliable if configured well.
Do I need to set up nameservers, or can I use external DNS?
You can do either. Panel-based nameservers are convenient for reseller hosting. External DNS (e.g., Cloudflare, Route 53) is simpler and often more resilient for single-business sites or agencies managing a few domains.
Will YouStable install and manage the panel for me?
Yes. YouStable’s managed VPS plans come with cPanel, Plesk, or DirectAdmin preinstalled, licensed, optimized, and monitored. We handle migration, backups, updates, and security so you can focus on growth.
With the right panel and a clean, secure installation, your VPS becomes a dependable hosting platform for websites, email, and apps. Follow the steps above, and you’ll have cPanel, Plesk, or DirectAdmin running smoothly in one session.