Currently we have to clear it manually everyday logging in to admin console and browsing to Home->Administration->Configuration->Development->Performance
Is there way we can automate this job in Drupal 8. We tried with "cron", but that didn't help.
Drupal Answers is a question and answer site for Drupal developers and administrators. It only takes a minute to sign up.Sign up to join this community
Despite you saying it didn't work with cron, I would suggest using cron in some way. :)
The CacheFlush module claims to allow configuration of this via its UI (although I haven't used it so cannot personally vouch for it).
If you are implementing custom code, drupal_flush_all_caches() will handle the flushing for you.
The Rules module also allows acting on Cron runs. Using rules you could either write a custom action that uses drupal_flush_all_caches() or find a module that provides one (I haven't seen any for D8 but that doesn't necessarily mean one doesn't exist).
You could also potentially do it outside of Drupal, using a cron job on your server to call
drush cr for your site.
Aside: I would suggest also considering why you need to do this and what alternatives there are. I can't really think of many (any?) cases where I would want to do this instead of just invalidating the cache of specific content entities/pages as they are changed.