Install and Configure phpMyAdmin with Apache on CentOS 7

Last modified on April 13, 2019 36 sec read

Today, I’ll show you how to Install and Configure phpMyAdmin with Nginx on CentOS 7. Let’s follow these steps:

Step 1 : Login to Server

At first, we need to login to our server via SSH. Open your terminal and run this command:

ssh [email protected] -p PORT

Step 2 : Install phpMyAdmin

First, we need to install EPEL repository. By typing this command, install EPEL repository if not installed:

sudo yum install epel-release

After installing EPEL repository, now we can install phpMyAdmin by typing this command:

sudo yum install phpmyadmin

Now, restart Apache:

systemctl restart httpd

To access the phpMyAdmin interface type this on a browser:


Step 3 : Configure phpMyAdmin

Accessibility: Normally, phpMyAdmin is only accessible from the localhost. If you want to access phpMyAdmin anywhere, open phpMyAdmin.conf:

sudo nano /etc/httpd/conf.d/phpMyAdmin.conf
<Directory /usr/share/phpMyAdmin/>
	AddDefaultCharset UTF-8
	Options Indexes FollowSymLinks MultiViews
	AllowOverride all
	Require all granted

Again restart the Apache:

sudo systemctl restart httpd

That’s it. Thank you.

Monthly Newsletter

One email a month, packed with the latest tutorials, delivered straight to your inbox.
We'll never send any spam or promotional emails.

Hey, I'm Md Obydullah. I build open-source projects and write on Laravel, Linux server, modern JavaScript and more on web development.