CDN
Learn how to improve performance of your Spree application by using a CDN (Content Delivery Network).
To improve performance of your Spree application, we recommend using a CDN (Content Delivery Network) to cache images and static files.
We recommend using Cloudflare as your CDN provider. It’s free and simple to setup.
After setting up your Cloudflare account and adding your domain name to Cloudflare, you will need to set your cache settings.
Go to your domain name in Cloudflare and click on “Caching” tab and select “Cache Rules”.
Click on “Create Rule” and setup the rule as bellow:
Supply the first value with
and the second value with
This will handle caching of both images and static files such as JavaScript and CSS files.
Now scroll down and set the settings as bellow:
Finally, click on “Deploy” and you are done!
Was this page helpful?