It does appear that WordPress requires an FTP server to be installed to upload the files from the web interface. I have installed WordPress blog. I need to install some plugins but i m getting a box :--

  To perform the requested action, WordPress needs to access to your web server. Please enter your FTP credentials to proceed. If you do not remember your credentials, you should contact your web host.

Something like this:-- enter image description here

Can u help me?

  • WordPress does not require FTP, but the way to let it know that is very obscure. Check my answer for explicit info. Jun 16, 2013 at 1:19

4 Answers 4


Tell WordPress to use the filesystem directly — add this line to the top of your wp-config.php:

define('FS_METHOD', 'direct');
  • 1
    Please don't just randomly throw 777 permission on folders without a need for it! codex.wordpress.org/…
    – faker
    Jun 16, 2013 at 16:06
  • @faker I agree, but I also have no idea what the correct permissions for the OP’s environment’s web user would be, and given that it’s a Linode, s/he’s probably already root, so there’s no imminent harm. Jun 17, 2013 at 2:25
  • That explains the first 7 only, and that only partially. It's worth pointing out that this also marks the entire wp-content directory (including its contents) executable, in case someone wants to upload something nefarious. Jun 17, 2013 at 8:25
  • I actually agree that define('FS_METHOD', 'direct') is the best way to solve this and it maybe would have worked without the chmod in the first place.
    – faker
    Jun 17, 2013 at 8:31
  • 2
    Classic failure of Stack Overflow’s power model. Rather than suggest an edit for my answer (which has been accepted as the correct answer), a deluge of downvotes. The entire SE network is going to shit. Jun 17, 2013 at 13:54

To install the VSFTP server on Ubuntu

sudo apt-get install vsftpd

Once you've got it installed you'll need to tweek the configuration, edit /etc/vsftpd.conf

Disable anonymous logins find the anonymous_enable directive and make it


Enable local accounts to login set the local_enable directive to


Allow writes by setting the write_enable directive


Restart the ftp server so your changes take effect.

sudo service vsftpd restart

  • how to create users? and write_enable doesnt exsts... :-( u want me to make a entry for that?
    – Mohit Jain
    Apr 2, 2011 at 10:01
  • @MohitJain yes, also by default write_enable=YES should be in there, just commented. you should only need to un-comment it Apr 25, 2014 at 16:48

In order to enable the use of SSH2 for your updates and theme uploads, you have to generate your SSH keys and have the PHP SSH module installed. Then WordPress will detect that you have SSH2 available and you'll see a different option (SSH2) displayed when doing an upload/upgrade.

1.) Make sure you have the PHP module installed for debian it is:

sudo apt-get install libssh2-php

2.) Generate SSH keys, adding a passphrase is optional:

cd  ~/.ssh
cp id_rsa.pub authorized_keys

3.) Change the permission so that WordPress can access those keys:

cd ~
chmod 755 .ssh
chmod 644 .ssh/*

Now you'll get the SSH2 option when doing an upload/upgrade/plugin. Here is a pic, I don't have enough rep. to post an image. Here is a link to the image that you'll get, hopefully this is okay to include. https://www.dropbox.com/s/1m7fxlkp0nchplx/ssh-connection.png

4.) For added ease you can setup the defaults in your wp-config.php and this will pre-populate the SSH credentials in the WordPress upload window.


The 'passphrase' is optional, if you don't setup a passphrase during ssh-kengen; then don't add it in wp-config.php

This solved my issue. And I didn't have to do the chown at all. But I have seen this method referenced in other places.



Actually, you do not need a ftp server running on your server to solve this problem.

If you are running nginx, just simply go to /path/to/yout/wordpress/ and type this command in your SSH connection window:

chown -R www .

I'm not sure how to change user permission if you are running apache, change www to the apache group name like httpd may will work:

chown -R httpd .

  • I am running apache and and i m getting this error:- chown: invalid user: `httpd'
    – Mohit Jain
    Apr 3, 2011 at 13:17
  • For Debian/Ubuntu it would be www-user
    – mikegrb
    Apr 14, 2011 at 2:01
  • I'm running nginx and chown -R www wordpress gives, invalid user 'www'. Running archlinux.
    – ArchNoob
    Sep 11, 2017 at 21:08

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .