Control Panels

How to Install aaPanel on a VPS or Dedicated Server (Step by Step, 2026)

Short answer: On a fresh server, log in as root, update the system, download aaPanel’s install script (install_7.0_en.sh) with certificate checks turned on, read it, then run it with bash. When it finishes, it prints the panel address, a random port, a security entrance path and the login details. Log in, change the password, install a web stack from the App Store, and lock the panel down before you add sites.

Before you install

  • ✓ A fresh VPS or dedicated server, with no web server, database or other control panel installed.
  • ✓ A supported Linux release. Ubuntu 22.04 or 24.04 and Debian 12 are good choices. Check aaPanel’s documentation for the current list.
  • ✓ At least 1 GB of RAM for a web server, PHP and a database. aaPanel itself needs little, but the stack does.
  • ✓ Root access over SSH, and console access in case you lock yourself out.
  • ✓ A domain pointed at the server if you want SSL for your first site straight away.

New to aaPanel? Our beginner’s guide to aaPanel explains what it does and how it compares with cPanel.

Step 1: log in and update the server

ssh root@your-server-ip

# Ubuntu and Debian
apt update && apt -y upgrade

# AlmaLinux and Rocky Linux
dnf -y update

Reboot if a new kernel was installed. Then start a screen session, so a dropped connection does not stop the installer:

apt -y install screen    # or: dnf -y install screen
screen -S aapanel

Step 2: download and run the installer

aaPanel’s one-line command downloads the script with certificate checks turned off. It is safer to download it normally, look at it, then run it:

curl -fsSL -o install_7.0_en.sh https://www.aapanel.com/script/install_7.0_en.sh
less install_7.0_en.sh          # read it, press q to quit
bash install_7.0_en.sh underhost

The installer asks you to confirm, then installs the panel. It takes a few minutes. When it finishes, it prints a block like this, with your own values:

aaPanel Internet Address: https://203.0.113.10:PORT/ENTRANCE
aaPanel Internal Address: https://10.0.0.5:PORT/ENTRANCE
username: xxxxxxxx
password: xxxxxxxx

Save these details in a password manager. If you lose them, run bt on the server to open aaPanel’s command menu, which can show the login address and reset the password.

Step 3: open the panel port

If your server has a firewall, allow the panel port only from your own IP address. With ufw on Ubuntu:

ufw allow from YOUR.IP.ADDRESS to any port PORT proto tcp
ufw status

Also check any firewall in your provider’s control panel.

Step 4: first login and web stack

  1. Open the Internet Address in your browser and log in.
  2. aaPanel suggests a software stack. Choose LNMP (Nginx) or LAMP (Apache), with a PHP version and MySQL or MariaDB.
  3. Pick the fast install option, then wait for the installs to finish in the task list.
  4. Change the admin password and user name in Settings.

Step 5: secure the panel

  • ✓ Keep the random security entrance, and do not share the full panel address.
  • ✓ Turn on two-factor authentication in Settings.
  • ✓ Turn on SSL for the panel itself, so you log in over HTTPS with a valid certificate.
  • ✓ Limit the panel port to your IP address, as in Step 3.
  • ✓ Use SSH keys for root, and turn off SSH password logins once your key works.

Step 6: add your first website

  1. Open Website > Add site, enter the domain, and choose the PHP version.
  2. Create a database at the same time if the site needs one.
  3. Upload the site files, or install an application.
  4. Once DNS points to the server, open the site’s SSL tab and request a Let’s Encrypt certificate.

Step 7: backups

In Cron, add a backup task for each site and database. Install a remote storage plugin from the App Store, such as S3-compatible storage or FTP, so copies are kept off the server. Test a restore once the first backup has run.

Troubleshooting

Problem Likely cause Fix
The installer stops with an error Unsupported system, or software already installed Reinstall the operating system and run the installer on a clean server.
The panel address does not load The port is blocked Allow the port in the server firewall and the provider firewall.
Lost the login details They were not saved Run bt on the server and use the menu to show the address or reset the password.
A site shows 502 Bad Gateway PHP-FPM for that PHP version is stopped Restart the PHP version in the App Store.

When a critical PHP release comes out, see our PHP security update guide, which includes aaPanel steps.

Need help with this?

Get aaPanel ready to use: choose it free when you order a Cloud VPS.

See Cloud VPS plansContact @CustomerPanel

Frequently asked questions

Which port does aaPanel use?

aaPanel 7 picks a random port and a random security entrance during install. Both are printed at the end of the installation.

Can I install aaPanel on a server that already runs websites?

No. Install it on a fresh server and move the sites afterwards.

How do I find my aaPanel login if I lose it?

Run bt on the server as root to open the command menu, which can show the login address and reset the password.

Does aaPanel need a lot of memory?

The panel itself is light. The web server, PHP and database need more, so plan for at least 1 GB of RAM.

Can UnderHost install aaPanel for me?

Yes. aaPanel is a free option on our Cloud VPS plans, or our team can install and secure it on your server.


Sources