Perhaps you've gone through the trouble of editing a template or some other code in Magento, refreshed your browser and found that nothing changes!

I'm embarrassed to say that I have personally gone around in circles changing, un-changing and re-changing settings wondering why my work is not being reflected in my browser.

I soon discovered what was going on and it made an immediate impact on my ability to quickly and confidently provide solutions to my clients.

Magento is likely caching your site.

Dynamic web applications like Magento and Wordpress have constantly struggled with balancing dynamics with performance. Most web applications dynamically craft the web pages that are consumed by your users. But dynamically generating web pages can be expensive and slow.

We can add a needed dose of performance to our websites by caching. Caching comes at the slight expense of loosing a measure of dynamics to our sites, though.

So, when we make code changes to our Magento sites we must force Magento to clear it's cache so no old, stale pages are delivered to users.

Flushing Cache

Whenever you make changes to your code you should flush Magento's cache to forcibly see the changes. Here's how you do it from command line:

Go to the root of your Magento installation. This might be ~/public_html, for example. It is the location where you see the app, bin and vendor directories.

Next, we're going to invoke the magento command-line tool through PHP like this:

php bin/magento c:c

This is just a shortcut of:

php bin/magento cache:clean

This clears the cache and allows you to immediately see you changes. Refresh your browser and see for yourself.

Conclusion

As you develop on platforms like Magento you can clear the cache to immediately see the results of your work.

Later I'll add more to this entry explaining other nuances of clearing the cache. Stay tuned.