Digital Ocean allows you to easily build a web server pre-configured for WordPress using their One-click apps. One apache module that is not installed and enabled by default is the expires module, a very beneficial tool for setting cache related settings on CSS, JS, images (and more) for your visitors. Many web hosting companies do not come with the expires module installed and enabled by default.
W3 Total Cache
The expires module allows you to set cache expiry dates for all file formats but most importantly your CSS, JS and images. Without this module installed W3 Total Cache will not work to it’s fullest capability as your website will not be leveraging browser caching to set long expiry headers on your files. This will also negatively affect your website performance score on websites like Pingdom.
Log into your server using SSH, the most common tool is to connect to your server is Putty, and run the following commands:
sudo a2enmod expires sudo service apache2 restart
After your expires module is enabled your css, js and images will have a long expiry set in your .htaccess and visitor browsers cache.