# phpMyAdmin — Web-Based MySQL and MariaDB Administration Tool > The most widely used web interface for managing MySQL and MariaDB databases, providing SQL editing, table management, and server administration from any browser. ## Install Save in your project root: # phpMyAdmin — Web-Based MySQL and MariaDB Administration Tool ## Quick Use ```bash docker run -d --name phpmyadmin -p 8080:80 -e PMA_HOST=your-mysql-host phpmyadmin/phpmyadmin # Open http://localhost:8080 and log in with MySQL credentials ``` ## Introduction phpMyAdmin is an open-source web application for administering MySQL and MariaDB servers. It has been the de facto standard for browser-based database management since 1998 and is bundled with most web hosting control panels worldwide. ## What phpMyAdmin Does - Browses, creates, edits, and drops databases, tables, columns, and indexes through a web UI - Executes arbitrary SQL queries with syntax highlighting and result export - Imports and exports data in SQL, CSV, XML, JSON, and other formats - Manages user accounts, privileges, and server variables - Displays server status, process lists, and replication configuration ## Architecture Overview phpMyAdmin is a PHP application that runs on Apache, Nginx, or any PHP-capable web server. It connects to MySQL or MariaDB via the mysqli or PDO_MySQL extensions. Session state is managed server-side in PHP sessions. Configuration is stored in config.inc.php with optional database-backed storage for bookmarks and history. ## Self-Hosting & Configuration - Deploy via Docker: `docker run -d -p 8080:80 -e PMA_HOST=mysql phpmyadmin/phpmyadmin` - Configure in config.inc.php or via environment variables (PMA_HOST, PMA_PORT, PMA_USER) - Enable blowfish_secret for cookie-based authentication security - Set AllowArbitraryServer to true to connect to multiple database hosts - Secure with HTTPS and restrict access via IP allowlists or reverse proxy authentication ## Key Features - Full SQL editor with auto-completion, syntax highlighting, and query history - Visual table designer for creating and modifying schemas without writing DDL - Multi-format import and export including compressed SQL dumps - Relation view showing foreign key connections between tables - Multi-server support for managing several database hosts from one instance ## Comparison with Similar Tools - **Adminer** — Single-file PHP alternative; phpMyAdmin has more features and a larger plugin ecosystem - **DBeaver** — Desktop-based universal database tool; phpMyAdmin runs in the browser with zero client install - **MySQL Workbench** — Oracle's official desktop GUI; phpMyAdmin is web-based and works on any device - **HeidiSQL** — Windows desktop client; phpMyAdmin is platform-independent and accessible remotely - **Beekeeper Studio** — Modern cross-platform SQL editor; phpMyAdmin is web-native and included in most hosting panels ## FAQ **Q: Is phpMyAdmin safe to expose on the internet?** A: Only behind HTTPS with strong credentials. Enable two-factor authentication and consider IP restrictions or a VPN for production servers. **Q: Can phpMyAdmin handle large databases?** A: Yes, though importing very large SQL files may hit PHP memory limits. Use the command-line mysql client for multi-gigabyte imports. **Q: Does phpMyAdmin support PostgreSQL?** A: No. phpMyAdmin is MySQL and MariaDB only. Use pgAdmin for PostgreSQL administration. **Q: How do I update phpMyAdmin?** A: With Docker, pull the latest image. For manual installs, download the new release and replace the application files, keeping config.inc.php. ## Sources - https://github.com/phpmyadmin/phpmyadmin - https://www.phpmyadmin.net/docs/ --- Source: https://tokrepo.com/en/workflows/31ccde3b-3ef0-11f1-9bc6-00163e2b0d79 Author: AI Open Source