Home / Localhost / localhost/phpmyadmin

localhost/phpmyadmin: how to open it and fix 404 or access denied

phpMyAdmin is the web tool for MySQL and MariaDB. How to open it in XAMPP, WAMP and MAMP, and fix 404, #1045 and #2002 errors.

A browser opening localhost/phpmyadmin, served from the htdocs folder of your local web server

Open this address: http://localhost/phpmyadminThis opens on your own computer. It only works if the program is running.

localhost/phpmyadmin opens phpMyAdmin, a web page for managing MySQL and MariaDB databases. It works only when Apache and MySQL are both running.

What runs on localhost/phpmyadmin

How to open phpMyAdmin

  1. Open your control panel (XAMPP Control Panel, WAMP, MAMP) and start Apache and MySQL.
  2. Open http://localhost/phpmyadmin. If Apache uses another port, add it: http://localhost:8080/phpmyadmin.
  3. XAMPP login: user root, empty password. MAMP login: root and root.

Install phpMyAdmin on Linux

Ubuntu / Debian: install
sudo apt install phpmyadmin php-mbstring php-zip php-gd php-curl
Ubuntu / Debian: restart Apache
sudo systemctl restart apache2

If localhost/phpmyadmin will not open

404 Not Found
phpMyAdmin is not installed or not set up in Apache. On XAMPP the folder is C:\xampp\phpMyAdmin. On Linux, install it as shown above.
This site can’t be reached
Apache is not running, or it uses a different port. Check the control panel.
#2002 Cannot connect: connection refused
MySQL is not running. Start MySQL in the control panel.
#1045 Access denied for user root
The password is wrong. See MySQL access denied for root.
Security
Never leave phpMyAdmin open to the internet with a weak or empty password. It is meant for your own computer.

Questions about localhost/phpmyadmin

What is the default phpMyAdmin login?
On XAMPP and WAMP the user is root with an empty password. On MAMP it is root and root.
Why does localhost/phpmyadmin show 404?
phpMyAdmin is not installed in your web server folder, or Apache is not set up for it. Check the install folder, or install the package on Linux.

Updated 2026-10-02

Config generators for this

Related pages