Disable render cache for a node type Is there a way to disable the render cache, which caches all the nodes by default, for a particular content type X.

I know we can disable the render cache site wide by commenting out

$settings['cache']['bins']['render'] = ‘cache.backend.null’;


in settings.local.php. But this is not a ideal approach for me as I need to disable the render cache only for a particular node type. 

Also, I need to disable the cache for both Authenticated and Anonymous users for the content type X.

Any pointers on the same would be very much appreciated.
Like you said disabling the render cache site wide is not a good idea. If you need this for one content type you can do this in a view alter hook.

If you want to disable caching for authenticated and anonymous users you have to set cache max-age = 0 and trigger the kill switch for the internal page cache:

function MYMODULE_node_view_alter(array &amp;$build, Drupal\Core\Entity\EntityInterface $entity, \Drupal\Core\Entity\Display\EntityViewDisplayInterface $display) {
  if ($entity-&gt;bundle() == 'article') {
    $build['#cache']['max-age'] = 0;
    \Drupal::service('page_cache_kill_switch')-&gt;trigger();
  }
}


The same can be implemented in a theme in a preprocess hook.