Linux – remove files and folders older than x days

When running cleanup scripts and you'd like to delete files and folders older than x days you can use the following commands:

For zip files:

find /path/to/your/folder/ -mtime +3 -name '*.zip' -execdir rm -- '{}' ;

For all files and folders:

find /path/to/your/folder/* -type d -mtime +1 -exec rm -rf {} ;