Trying to disable all cache types in Magento 2 from System > Tools > Cache Management.

But all I get is the following error:

Deployment config file env.php is not writable.

I tried making app/etc/env.php writable (777) but still no luck.

  • any update? also facing the same issue even with change of app/etc/env.php writable Oct 7, 2016 at 6:30
  • Even with both config.php and env.php set to writable, it's still giving me that error..
    – Erfan
    Dec 21, 2016 at 9:50

2 Answers 2


First of all connect to your web server with your telnet software.

Change directory with cd <magento dir>/app/etc

Type chmod -R 777 /var/www/html/magento/app/etc to change mode for env.php file to be writable.

sudo chmod -R 777 app/etc/env.php

I hope this helps you !!

  • Should never use 777 in production, read up on it. Aug 22, 2018 at 15:22

I too had the same issue in Magento 2.1.2 with message being returned as "Deployment config file env.php is not writable.".
But it got resolved when I additionally set the write permission for app/etc/config.php apart from the env.php file

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.