install/update WordPress plugins without providing FTP access?

install/update WordPress plugins without providing FTP access?

One day I am going to install a plugin on my WordPress Blog. But it’s appearing that you need to enter your FTP login to install the plugin. I am trying to find the solution How to install/update WordPress plugin without providing FTP access to WordPress. I just want to allow WordPress to directly install/update WordPress plugins without providing FTP access.

Install WordPress plugins without providing FTP access

WordPress Asking for FTP detail because First, WordPress create the temporary file in the wp-content directory. Then, WordPress check the file permission and Ownership of the file with its own UID. and if there is a match it will allow you to use the ‘direct’ method of installing plugins, themes, or updates.

If you don’t want to change the permission on a wp-content directory, and your server has to write permission, Then add this line to your wp-config.php file.

define('FS_METHOD', 'direct');

After, Adding this line WordPress never asking for FTP access. Read this for more detail about WordPress file permission and FS_METHOD. WordPress directly install/update plugins and themes. Still, If you face any issue write the comment below.