Where Is Php Ini Godaddy

Other Programming Languages

I recently had the pleasure of working on a website hosted on GoDaddy, and one of the tasks I needed to complete was to locate the php.ini file. As a developer, I rely on this file to make crucial adjustments to the PHP configuration, so finding it quickly was essential. In this article, I will guide you through the process of locating the php.ini file on GoDaddy and share my personal insights along the way.

When I first started my search for the php.ini file on GoDaddy, I was a bit perplexed. The usual locations where I would find the file on other hosting providers didn’t seem to apply here. However, after diving into the documentation and reaching out to GoDaddy’s support team, I discovered that the php.ini file is not directly accessible on their shared hosting plans. This is a security measure implemented by GoDaddy to prevent users from interfering with the server configurations.

So, if you cannot directly access the php.ini file on GoDaddy, how can you make necessary modifications to the PHP configuration? GoDaddy provides an alternative solution by allowing users to create a custom php.ini file or modify specific PHP settings using a user.ini file. Let’s explore both options in more detail:

1. Creating a Custom php.ini File

To create a custom php.ini file on GoDaddy, follow these steps:

  1. Log in to your GoDaddy account and navigate to the cPanel dashboard.
  2. Locate the “Files” section and click on “File Manager.”
  3. Select the document root directory of your website (usually public_html).
  4. Click on “New File” and name it php.ini.
  5. Right-click on the newly created php.ini file and select “Edit.”
  6. Add your desired PHP configurations to the php.ini file using the appropriate format.
  7. Save the changes and exit the file editor.

By creating a custom php.ini file, you can override specific PHP settings to suit your needs. Keep in mind that changes made in the custom php.ini file will only affect the specific directory where it is placed.

2. Using a user.ini File to Modify PHP Settings

If you prefer to modify PHP settings without creating a custom php.ini file, GoDaddy also allows the use of a user.ini file. The user.ini file functions similarly to php.ini but has some limitations. Here’s how you can use a user.ini file to modify PHP settings on GoDaddy:

  1. Access your cPanel dashboard and navigate to the “Files” section.
  2. Click on “File Manager” and select the document root directory of your website.
  3. Locate or create a .htaccess file in the document root directory.
  4. Edit the .htaccess file and add the following line of code:

SetEnv PHPRC /path/to/your/user.ini

Make sure to replace /path/to/your/user.ini with the actual path to your user.ini file.

Once you have the user.ini file set up, you can add your desired PHP configurations using the same format as in the php.ini file. Please note that not all PHP settings can be modified via user.ini, as GoDaddy restricts certain configurations for security reasons.

Now that you know how to create a custom php.ini file or use a user.ini file on GoDaddy, you can make the necessary changes to your PHP configuration. Remember to test your website thoroughly after making any modifications to ensure everything is functioning as expected.


While locating the php.ini file on GoDaddy’s shared hosting plans may not be as straightforward as on other platforms, you have alternative options that allow you to make crucial modifications to your PHP configuration. By following the steps outlined above, you can create a custom php.ini file or utilize a user.ini file to tailor the PHP settings to your needs.

GoDaddy’s focus on security by restricting direct access to the php.ini file ensures the stability and integrity of their shared hosting environment. Although it initially posed a challenge for me, I appreciate their efforts in safeguarding the server configurations.

So, the next time you find yourself in a similar situation while hosting your website on GoDaddy, remember that you have options to customize your PHP configuration without direct access to the php.ini file.