There may be times you need to view your account's php settings. In order to do that you will want to create a phpinfo page. If you need to update any of your php variables, please see our article on updating your local PHP settings.

Creating a phpinfo page:

In this walk through we will use the cPanel File Manager to create our phpinfo page.

  1. Start by logging into your cPanel
  2. Open File Manager
  3. Make sure you are in the directory you want to put the phpinfo page into. For instance, if you are making a phpinfo page for your main domain name, you will want to be in the public_html directory. If you're creating a phpinfo page for an Addon domain, navigate to public_html/addondomain.com
  4. Click on the "New File" File icon at the top of the page
  5. In the dialog box that appears asking you for a file name, type in phpinfo.php. Note: this file can actually be named anything you want it to be, phpinfo is just the most common name for this file)
  6. Locate your new phpinfo file, right click it and select either "Edit" or "Code Edit" from the menu. If a "Text Editor" prompt appears, in the drop down list, choose "utf-8" and then click the "Edit" button.
  7. In the editor, type in the following text:
  8. <? phpinfo(); ?>

  9. Click the "Save Changes" button.


That's all there is to creating a phpinfo.php file.

Viewing Your phpinfo Page

To view your newly created phpinfo page simply navigate to YourDomain.com/phpinfo.php. You should see a page similar to:

phpinfo

If you need to see a specific value for a setting, use your browser's search feature (Ctrl + F in Windows or Command + F for Mac). For instance, if I wanted to find the memory_limit setting, I would search for memory_limit setting. The first column shows the local value and the second column shows the master value. The local value overrides the master value so it is the one to look at and determine if you need to make any changes to.

phpinfo-memory_limit

It's important to understand that the phpinfo file shows your individual php settings. Because phpinfo.php is a common file name, there are potentially malicious "bots" on the web that will search for that file name. It's best practice to do one of the following when you are finished

  • Delete the file
  • Rename it to something hard for other to guess
    (Keep in mind that it may be difficult for you to remember that filename)
  • Move the file above public_html
Did you find this article helpful?

We value your feedback!

Why was this article not helpful? (Check all that apply)
The article is too difficult or too technical to follow.
There is a step or detail missing from the instructions.
The information is incorrect or out-of-date.
It does not resolve the question/problem I have.
How did you find this article?
Please tell us how we can improve this article:
Email Address
Name

new! - Enter your name and email address above and we will post your feedback in the comments on this page!

Did you find this article helpful?

Post a Comment

Name:
Email Address:
Phone Number:
Comment:
Submit

Please note: Your name and comment will be displayed, but we will not show your email address.

Related Questions

Here are a few questions related to this article that our customers have asked:
Ooops! It looks like there are no questions about this page.
Would you like to ask a question about this page? If so, click the button below!
Need More Help?

Help Center Search

Current Customers

Email: support@WebHostingHub.com Ticket: Submit a Support Ticket
Call: 757-416-6627 Chat: Click To Chat Now

Ask the Community

Get help with your questions from our community of like-minded hosting users and Web Hosting Hub Staff.

Not a Customer?

Get web hosting from a company that is here to help.
}