Sometimes you may need to access your Joomla database through phpMyAdmin, for example to modify settings, restore data, or troubleshoot issues. If you do not remember the database credentials that were configured during installation, you can retrieve them from Joomla’s configuration file.
Important: Do not change the database password from the mybox Panel unless you also update the Joomla configuration file. Otherwise, your website will no longer be able to connect to the database.
Table of Contents
Step 1: Connect to the Server via FTP
Connect to your hosting account using an FTP client such as:
- FileZilla
- WinSCP
- Cyberduck
Use the FTP credentials assigned to your website.
Step 2: Locate the Joomla Installation Directory
Navigate to the directory where Joomla is installed.
In most cases, the website files are located in:
yourdomain.com/public_html Inside this directory, locate the file:
configuration.php Step 3: Open the Configuration File
Download the file or open it directly for editing using your FTP client.
Search for the following lines:
public $host = 'database_host';
public $user = 'database_user';
public $password = 'database_password';
public $db = 'database_name'; Understanding the Values
| Parameter | Description |
|---|---|
$host | Database server hostname |
$user | Database username |
$password | Database password |
$db | Database name |
Example:
public $host = 'example.mysql.mybox.com';
public $user = 'example_user';
public $password = 'MySecurePassword123';
public $db = 'example_database'; These values can be used to log in to phpMyAdmin or connect to the database from another application.
Using the Credentials in phpMyAdmin
After obtaining the information from configuration.php:
- Open phpMyAdmin from the mybox Panel.
- Enter the database username.
- Enter the database password.
- Log in to access the database.
Security Recommendations
- Never share the contents of the
configuration.phpfile publicly. - Do not send database credentials via unsecured communication channels.
- Keep a backup of the file before making any changes.
- Avoid editing database settings unless necessary.
Summary
To find your Joomla database credentials, connect to your website via FTP and open the configuration.php file located in the Joomla installation directory. The database hostname, username, password, and database name are stored in the following configuration variables:
public $host = 'database_host';
public $user = 'database_user';
public $password = 'database_password';
public $db = 'database_name'; These credentials can then be used to access the database through phpMyAdmin or other database management tools.