2 min read

How to disable cache in Drupal 8 for development

Applies to: Drupal 8.1.x

In Drupal 7, we had the ability to disable caching through the Drupal UI, so we did not need to use drush cc after every small change. In the Drupal settings, the “Minimum cache lifetime” option could be set to “None” to effectively disable caching.

Drupal 7 cache configuration Drupal 7 cache configuration

Unfortunately, in Drupal 8, we no longer have the ability to do this via the Drupal UI. The only option available is “Page cache maximum age,” which is mainly used by browsers and proxy servers. If you are not using a proxy cache, this setting only affects the browser, and Drupal 8 will still use its internal caching mechanisms.

Drupal 8 cache configuration Drupal 8 cache configuration

However, in Drupal 8, you can still disable caching through configuration files. You can find official documentation on how to disable Drupal 8 caching during development at drupal.org.