wp-config.php of my WordPress

The wp-config.php is one of the most important parts of our WordPress.

This file allows us to perform the basic configuration of any WordPress, as it is where the main "low level" options are that allow us to have the CMS working.

The wp-config.php file is a PHP file, but it has little code that executes. Instead, it has parameters and variables that are what define the correct functioning of the WordPress installation.

You can edit this file through the File Manager provided by the SWPanel (you can also access it via FTP or SSH). To locate it, you must go to the root directory of your website (/data/web), here is the procedure:

1- Enter the dashboard of the hosting service where you host your WordPress looking for it in the SWPanel:

The screenshot is for guidance only. It was taken on version 2024.07.0123 with date 24/10/2024. It may differ from what the current version of SWPanel displays.

2- Access the file manager by clicking on Service management -> File manager:

The screenshot is for guidance only. It was taken on version 2024.07.0123 with date 24/10/2024. It may differ from what the current version of SWPanel displays.

3-Locate the file wp-config.php inside the hosting service folders (/data/web/wp-config.php):

The screenshot is for guidance only. It was taken on version 2024.07.0123 with date 24/10/2024. It may differ from what the current version of SWPanel displays.

4- Place the mouse over the three dots on the right side of the wp-config.php file and click Edit file:

The screenshot is for guidance only. It was taken on version 2024.07.0123 with date 24/10/2024. It may differ from what the current version of SWPanel displays.

MySQL Data

This is the access data that WordPress uses to connect the website to the database. WordPress cannot function without a database.

It corresponds to these lines:

/** The name of the database for WordPress */
define( 'DB_NAME', 'NAME_WP' );

/** MySQL database username */
define( 'DB_USER', 'USER_WP' );

/** MySQL database password */
define( 'DB_PASSWORD', 'Password123' );

/** MySQL hostname */
define( 'DB_HOST', 'localhost' );

In case this configuration does not correspond with the data we have in our Hosting, we could encounter a database connection error. 📃 Manual: Error to establish a connection to the database in WordPress

FTP data

The FTP account data that has been created in our Hosting is also shown: 📃 Manual: Adding FTP data in WordPress

define('FTP_HOST', 'swmanuales.com');
define('FTP_USER', 'USER_WP');
define('FTP_PASS', 'Password123');

Mail data

If we want to 📃 Manual: Configure plugin for sending mail (WP Mail SMTP) in WordPress in our WordPress, we must take into account the email account and password used by WordPress:

define('WPMS_SMTP_USER', '[email protected]');
define('WPMS_SMTP_PASS', 'Password123');

Debug mode

The wp-config.php file is essential to be able to enable debug mode on our website: 📃 Manual: How to activate debug mode in Wordpress

define('WP_DEBUG',  false);
define('WP_DEBUG',  true);

2025 DeepThink Software SLU. All rights reserved. The prices shown on the website do not include any applicable taxes.