Database administration on a Linux server often needs a browser interface for inspecting schemas, running SQL, and managing accounts. The distribution package supplies phpMyAdmin with the PHP modules and Apache integration expected by Ubuntu and Debian.

The Apache package path is the single method used here. A MySQL or MariaDB server should already be installed and reachable because the phpmyadmin package installs a database client and web dependencies, not the database server itself.

The installer can create phpMyAdmin configuration storage through dbconfig-common. This optional database supports advanced features such as bookmarks and saved preferences; declining it leaves the ordinary login interface usable and avoids requesting database-administrator credentials during installation.

Steps to install phpMyAdmin on Ubuntu or Debian:

  1. Refresh the APT package index.
    $ sudo apt update
  2. Install phpMyAdmin from the distribution repository.
    $ sudo apt install phpmyadmin
  3. Select apache2 in the Web server to reconfigure automatically prompt.

    The package enables its Apache configuration at /etc/apache2/conf-enabled/phpmyadmin.conf.

  4. Choose No at the Configure database for phpmyadmin with dbconfig-common? prompt.

    This skips optional configuration storage without disabling the phpMyAdmin login page.

  5. Test the packaged Apache configuration.
    $ sudo apache2ctl configtest
    AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 192.0.2.10. Set the 'ServerName' directive globally to suppress this message
    Syntax OK

    The AH00558 line is a hostname warning, not an installation failure. Syntax OK confirms that Apache can parse the enabled phpMyAdmin configuration.

  6. Verify that the local phpMyAdmin endpoint returns a successful HTTP response.
    $ curl -I --fail http://127.0.0.1/phpmyadmin/
    HTTP/1.1 200 OK
    Server: Apache/2.4.66 (Ubuntu)
    ##### snipped #####
    Content-Type: text/html; charset=utf-8

    The loopback URL checks the server locally. Remote browser access also depends on the host firewall, DNS, and TLS configuration.