Why WordPress Asks for FTP Credentials & How to Fix It

Share This Post

Share on facebook
Share on linkedin
Share on twitter
Share on email
Share on pinterest

WordPress is one of the most popular content management systems that has facilitated the creation and running of more than 75 million websites. It has become so popular because it is one of the simplest services to use for making a website and offers a wide variety of plugins for customization, all while remaining free or very low cost.

Why does WordPress ask for FTP credentials and how to fix it? When you try and update or add plugins, WordPress may not think it has permission to modify, add or remove files from the server where it is installed. To fix this problem, you can enter your credentials, override the changes with code, or update directory permissions.

If you are not super tech savvy, don’t worry, we have given you a helpful guide with clear steps to troubleshoot these issues yourself. There are multiple ways that you can fix this problem so you can get back to working on your website.

Why Does WordPress Ask For FTP Credentials?

Before understanding how to fix the problem, it may make a bit more sense if you understand why it is happening. This will help to prevent future problems and give you more knowledge related to the coding and programming that goes on behind the scenes of your easy interface and website creation through WordPress.

What are FTP Credentials?

FTP stands for ‘File Transfer Protocol,’ and it allows you to directly send files from one host to another. Having these credentials lets you make changes to your WordPress directly and you don’t have to go through your dashboard to do it. While this may require some extra code, having it can make your life much simpler for changes.

All of the information and files on your WordPress are attached to a server, and having FTP credentials allows you to access these directly from your computer. Changes that you make when your credentials are entered will automatically be saved to the server.

Having your FTP credentials will allow you to make changes to your WordPress site, and the most relevant ones to you are installing and updating both plugins and themes for your website.

Why Does WordPress Ask for Them?

When you try to make changes or add and update plugins, WordPress may ask for your FTP credentials. This can be a bit frustrating as you are just trying to make some simple additions to your site and don’t want to jump through these extra hoops. WordPress does this to ensure that changes are being made by qualified parties.

WordPress asks for these credentials when it does not have direct access to the files you are trying to use.

Having these credentials will ensure that you are allowed to make changes to the website. You should be aware that by entering these credentials, you may be making changes that are difficult to undo, and we’ll cover how to protect yourself from permanent errors in the FTP credential solutions section.

The problem with WordPress asking for these credentials is that most users do not know what to do or how to fix the problem, and this can be frustrating. They may choose not to update their plugins, causing them to miss out on new features and software for the most up-to-date website tools.

How to Fix WordPress Asking for FTP Credentials

Because you cannot make your updates or add plugins without WordPress asking for these credentials, we have pulled together multiple solutions so you can get past this inquiry. These solutions will vary based on your goals, level of difficulty, and ability to work with the code and processing of your computer system.

Solution 1: Enter FTP Credentials

The simplest way to solve the problem of needing credentials is to enter them! If you have these credentials, you can put them in, but if you don’t, you will need to get them from your server. You should have been sent a username and password when you set up your domain, but you can contact your server host if you can’t find the information.

Entering FTP credentials into a file manager is one of the safest and easiest ways to avoid WordPress, asking for these credentials in the future. You are giving the program permission to make changes directly from your computer with a log-in that was given to you by the server. You will be changing your wp.config.php to make this happen.

While it does require a few steps, follow these to enter your FTP credentials safely:

    1. Have a file manager: You will be inputting code with your credentials to tell WordPress that you don’t need to enter FTP credentials in the future. A file manager will allow you to keep track of and input this important information to keep your WordPress running. FileZilla is a popular file manager that WordPress actually recommends (it is free and easy to use).
    2. Open wp-config.php: This file is located in your file manager and will bring up a screen of code. This is the information that WordPress uses to keep and gather data needed to successfully run your website.
    3. Insert code: You will need to add in your credentials with code onto this configuration page. We have provided the code for you to copy and paste into your file manager, but just make sure that you edit this code with your data. The areas you need to change are highlighted:define(‘WP_DEBUG’, false);define(‘FTP_USER’, ‘YOUR FTP USER‘);define(‘FTP_PASS’, ‘YOUR FTP PASSWORD‘);define(‘FTP_HOST’, ‘YOUR FTP HOST‘);define(‘FTP_SSL’, false); //Change to True if you are using SSL FTP

      define(‘FS_METHOD’,’direct’);

      You may only need to include the last line of code to fix your FTP credential pop-up problems. You can start with the last line of code and see if that fixes your problem:

      define(‘FS_METHOD’,’direct’)

      If nothing changes after this addition, you should add in the remaining code and input your FTP credentials.

  1. Save changes: Make sure you save the changes you have made to the wp.config in the file manager before closing and refreshing the program.

This is the safest and easiest way to make changes to your program in order to work directly between your computer and the server. This is a helpful YouTube video that outlines these steps if you want a visual to follow along with.

Solution 2: Change Permission in File Manager

If the last solution didn’t work for you (it should work in most cases, but some servers don’t run on FTP), you may need to edit permissions in your file manager. This will bypass questions such as FTP to give you more freedom to make changes. At the same time, this can be a bit riskier because it changes the security of your site and could be open to hackers.

In order to use certain plugins for your WordPress site, permissions may have needed to be changed at some point in order for these files to be accessible. There is a specific coding system known as a ‘permission code’ that you can set in order to dictate who has access to files and what can be changed.

Permission Code Format

In this coding system, there are three numerical values that all represent the amount of access that specific parties have. These are inputted with a three digit number:

X X X
1st Number: Owner privileges 2nd Number:

Account User Privileges

3rd Number:

All other users (including public)

  • First number: This number dictates the power and access for the owner of the account. This should be the person who is in charge of the website and who will need access to make the most changes.
  • Second number: This value indicates what the users who are given website responsibilities can do. They are not the owner of the account, but they are given permission and access to the website for changes. This may be an employee or technical staff.
  • Third number: This value represents any other user account that is not included in the user accounts that are meant to make changes. This can include people who visit the WordPress site and any public accounts.

You will then be able to assign a number that represents a specific amount of privileges that the user has. A ‘4’ means that the party has permission to read the file, ‘2’ gives permission to change or write a file, and a ‘1’ allows a user to run a file. Changing these for different users is very important as it gives the proper parties access to information.

Here is a helpful table that designates what each value will give permission for:

Number Value Permission
0 Parties assigned with this value are given no permissions for the site.
1 This allows for execution privileges only.
2 This allows for writing privileges only.
3 This allows for writing and executing privileges.
4 This allows for reading privileges only.
5 This allows for reading and executing privileges.
6 This allows for reading and writing privileges.
7 This is the most privileges that can be assigned to a party and they allow for reading, writing, and executing privileges.

The value that ends up in the 3-digit value is the sum of permissions you provide each party. For example, an owner of the account may have full access to read (4), write (2), and execute (1). This would give them a value of 7. If all parties have these privileges, your final permission code would be 777 (we do not recommend for security risks).

Selecting A Permission Code

Choosing a permission code that gives you enough access to avoid the FTP credential page is helpful, but it can also be a security risk. If you are the owner of the account, you will need to make careful changes to the permission code in order to make your necessary changes without giving too many privileges to other parties.

Anyone with access to the file manager can make these changes, so make sure when the WordPress site is being set up, only the qualified parties have access. This should be reserved for the owner and certain group account members.

These are the steps you take to change the permission code:

  1. Open file manager: This could be FileZilla or any other program that is organized to hold all your important files related to WordPress and other programs.
  2. Look for wp-content: Once you find this folder, you will want to right-click on ‘file permission.’ This will allow you to make the necessary changes to the value.
  3. Select numerical value: There will be a small box with the current permission code value. You can type in your desired value here.
  4. Save changes: Make sure you save the changes in order to update the new permissions.

We recommend setting the number to 744 because it gives full access and permissions to the owner of the account and restricts members and other visitors to ‘read only’ for safety.

If all users need access to the program, 755 is a common setting to give permission for reading and executing. A 700 setting gives only the user access and keeps information private from all other parties. Avoid 777 as it can be unsafe to give access to any visitor to your site. This is a helpful video for choosing and following along with these changes.

Solution 3: Combination of Code and Permissions

There are multiple paths to solving this issue, and we want to give you as much information as possible in the event that a few of them are unsuccessful with your specific programming. You can take some ideas from both of the solutions above and enter them in order to reach a solution.

Follow these steps to fix the problem:

  1. Open wp.config.php: This will be found in the file manager that you are using and will open up to a series of code.
  2. Paste code: You will want to paste this code (similar to the last step in the first solution) at the end of the file: define(‘FS_METHOD’,’direct’);
  3. Access console: Open your droplet access console, and you will need to enter new code there as well: chmod (XXX) /yourwebsitename/public/wp-content/plugins/

Where the XXX values are is the permissions value you will enter. Make this the value of the access you want different parties to have. You will also need to replace the section that says ‘your website name’ with your data. Be sure to save all changes after these are made, and it should solve your FTP credentials issue.

Sometimes just entering the code: define(‘FS_METHOD’,’direct’); (copy and paste) can solve the issue. Consider trying this, so you don’t have to make permission changes. You may be more likely to need permission changes if you set up WordPress up by yourself rather than having someone with more experience set these properly for you.

Making Your Life Easier Using WordPress

An image of a person sitting at a desk with their computer open leaning back in their chair

So many people use WordPress to create and manage their websites because it is a user-friendly interface that is easy to use and straightforward. When you run into issues with FTP credentials and not having the proper permission to make changes and add or update plugins, this can be quite frustrating.

We have come up with three solutions that are fairly straightforward to do yourself and safe. Our solutions emphasized ways to make changes that will allow you to maintain your site security while also expanding the permission settings to make changes much easier.

There are more drastic changes you can make to your directory settings, but these are often permanent and pose security risks that we don’t recommend. When you do make changes to FTP settings or any code in order to solve these issues, we recommend a couple of things:

  • Backups: Make sure that before you make any changes, you have backed up the coding and all setting information. For all experience levels, mistakes can be made. Most of these are fixable, but it will save you a lot of time and effort if you have the original settings that you can revert back to easily.
  • Save changes: Once you have made the changes, make sure they are saved. You will not only have the FTP credential page prompted again, but you will have to go back and work through these steps all over. Save yourself time!
  • Consult your team: If you are a member of the group account, you will want to make sure you are consulting the owner of the account or other team members to ensure that changes are allowed to be made. As an owner, be aware of the permissions you are giving your group and especially to those that are given to any visitor of the site.

While coding and making these changes can be a bit overwhelming to those without a ton of experience, following these steps closely can help you fix the issues you are having any time you try to add a plugin on your WordPress site. Once you have made these adjustments, you won’t have to worry about this pop up anymore!

Share This Post

Share on facebook
Share on linkedin
Share on twitter
Share on email
Share on pinterest

More To Explore

Do You Want To Boost Your Business?

An image of three people in a meeting looking at laptops