In this tutorial, you will learn how to fix the “Destination directory for file streaming does not exist or is not writable” error in WordPress when you try to install a new plugin.
This error is caused by incorrect permissions for the wp-content/uploads folder. WordPress needs to create a temporary folder to place the files when downloaded, before installing a new plugin.
You will have to connect over FTP and check the permissions for the folders in wp-content and make sure that they are all using 755 instead of 777.
Additionally, you can create a temporary folder outside of the install directory (e.g above public_html). In other words, find the document root folder of your site and go up a directory. As we are now outside of the public directory, we can now create a folder called ‘wordpress_temp’ with 777 permissions and not create a security hole.
The next step is to edit the wp-config.php file in the document root directory and add the following line at the bottom.
define('WP_TEMP_DIR', ABSPATH . '/../wordPress_temp/');
You can now return to your WordPress admin panel and try to install a new plugin without any error.