Magento – magento2 admin dashboard not loading css and js

cssjavascriptmagento-2.1.9reindex

admin pannel of M2 v2.1.9 not loaded in css and js file means show only html content format.

I'm also run these commond many times but not fix.

  • sudo php -f bin/magento setup:static-content:deploy
  • php bin/magento setup:di:compile
  • php bin/magento indexer:reindex
  • sudo chmod -R 777 var/

Delete Some Folder too:

  • MAGENTO_ROOT/pub/static/_requirejs
  • MAGENTO_ROOT/pub/static/adminhtml
  • MAGENTO_ROOT/pub/static/frontend

Can anyone guide how to fix it?

Best Answer

Please check it out if static contain .htaccess file or not if not then paste it from this link https://github.com/magento/magento2/blob/2.2-develop/pub/static/.htaccess and do this command

sudo php bin/magento setup:static-content:deploy
sudo php bin/magento cache:flush

Thanks

Related Topic