I've tried to install Magento 2 locally using XAMPP. This works fine, except for the fact that when I alter my CSS, HTML, or JS, XAMPP won't get the updated files. It just takes the file I initially created with its content, but not the updated version.

I think this has something to do with caching of Apache itself? I read something about disable cache using .htaccess (http://httpd.apache.org/docs/2.0/mod/mod_cache.html) but I can't figure out how to implement this.

Does anyone know how I can fix this?

Flushing cache doesn't work. Deploy static content may work, but I don't want to do that every time I make one minor change in the CSS (when I worked remotely, I did not have to do that either)

The developer mode is enabled.

  • have you tried after cache flush and static content deploy commands?
    – kunj
    May 31, 2018 at 11:10
  • Yep. I used to work remotely, which would not have me to constantly deploy the static content or flush the cache when I alter the css. When I flush the cache working locally, it won't update.
    – Condor
    May 31, 2018 at 11:12
  • For windows env. I will prefer to use Git bash.
    – MR.R DNATH
    May 31, 2018 at 11:16
  • @MR.RDNATH how is that related to my question?
    – Condor
    May 31, 2018 at 11:17
  • you can use grunt for CSS and for JS you can use magento developer mode.
    – kunj
    May 31, 2018 at 11:17

1 Answer 1


If you are just working locally, try enabling developer mode. With the developer, mode enabled you won't need to redeploy the content all the time. You will need to flush the cache but if you are working on a decent machine with an SSD, you can also disable the cache through the admin.

You can enable developer mode in several ways but a quick way is just to edit the "app/etc/env.php" file. There should be a line that says "'MAGE_MODE'". By default I think it says:

'MAGE_MODE' => 'default',

it should be as simple as changing it to:

'MAGE_MODE' => 'developer',

and then flushing or disabling the cache. I really don't recommend disabling the cache unless you are working off of an SSD. It is unusably slow on a normal drive.

  • As you can see in my question, unfortunately I already have developer mode enabled and flushing the cache doesn't work. I think this may not be Magento 2 related so I will post my question on stack overflow
    – Condor
    May 31, 2018 at 12:58

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.