What Is PhpMyAdmin
PhpMyAdmin is a free software tool written in PHP, designed to manage MySQL over the Internet. phpMyAdmin supports a wide range of operations on MySQL and MariaDB databases. Frequently used operations (managing databases, tables, columns, relationships, indexes, users, permissions, etc.) can be performed through the user interface, while you still can directly execute any SQL statement.
Let’s Set PhpMyAdmin
Install phpMyAdmin from default Ubuntu repositories
sudo apt update
sudo apt install phpmyadmin php-mbstring php-gettext
sudo phpenmod mbstring
sudo systemctl restart apache2
Customize user authentication and privileges
sudo mysql
Configure the root account for password authentication and don’t forget to change the password password:
SELECT user,authentication_string,plugin,host FROM mysql.user;
ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'password';
FLUSH PRIVILEGES;
exit```
> **Security note:** Never expose phpMyAdmin publicly on the internet. Restrict access with Apache `.htaccess` (using `Allow from` directives) or Nginx `auth_basic` to trusted IPs only. For occasional database access, consider [Adminer](https://www.adminer.org/) — a single-file, lighter alternative. On modern servers you can also use the `mysql` CLI directly or a desktop GUI client like DBeaver or TablePlus.
### Security note
Never expose phpMyAdmin on a public IP without authentication. Add an .htaccess password or nginx auth_basic before the phpMyAdmin location block. For quick database queries, consider [Adminer](https://www.adminer.org/) — a single PHP file alternative with no installation required and a smaller attack surface. Related What I Do
Related What I Do
These What I Do pages are matched from the subject matter of this article, creating a cleaner path from educational content to implementation work.
Continue reading
Related articles
Based on shared categories first, then the strongest overlap in tags.