CloudLinux.ro
Web servers

How to install phpMyAdmin to manage MySQL from the browser

Updated 7/20/2026

phpMyAdmin lets you view and edit MySQL databases from a browser, without the command line. Here is how to install it safely.

1. Install

apt-get update -y
apt-get install -y phpmyadmin

When prompted, choose the web server (Apache) or configure it manually for Nginx via a symlink:

ln -s /usr/share/phpmyadmin /var/www/mysite/phpmyadmin

2. Securing it, mandatory

phpMyAdmin is a frequent target. Protect it:

  • Serve it only over HTTPS (see Let's Encrypt).
  • Add an extra password at the web server level (basic auth).
  • Do not use the MySQL root account; create a dedicated user (see MySQL users and privileges).
  • Ideally, restrict access to your own IP.

A lighter alternative

For a single file, no install, you can use Adminer (adminer.php), which offers the same functionality much more simply.

Put this guide into practice on your own VPS

EU cloud servers, billed hourly, ready in minutes, with one-click installs for dozens of apps.

See pricing

Related tutorials