I made a backup of Magento 2 and copied the whole site to another host. I extracted files and created a database. Now I get no CSS loaded. They all are "missing".

First I thought that it was caching or rewrite module problem, but now I found that if I deploy the static content, only en_US is deployed, although my default is ru_RU (this is where the CSS files are attempted to be loaded from).

3 Answers 3


The main command it's below that will deploy the en_US and ru_RU:

php -f bin/magento setup:static-content:deploy en_US ru_RU

If doesn't work run these commands:

alias mage="php -d memory_limit=-1 -f bin/magento"

chmod -R 775 pub/static/ var/ pub/media/ &&
rm -rf var/view_preprocessed/ var/cache/ var/page_cache/ var/tmp/ var/generation/ pub/static/frontend/ ;
php -r "opcache_reset();"
mage deploy:mode:set developer;
mage setup:static-content:deploy en_US ru_RU;
mage cache:flush &
mage indexer:reindex &
mage setup:upgrade &&
mage setup:db-data:upgrade &&
mage dev:source-theme:deploy &&
chmod -R 775 pub/static/ pub/media/ var/
  • php bin/magento setup:static-content:deploy en_US ru_RU -f Commented Aug 14, 2020 at 11:28

You need to run deploy command for all languages as below.

php bin/magento setup:static-content:deploy en_US ru_RU

Please run following ssh command on the magento directory. Please, check your directory(using pwd command ) before running any command.

1- rm -rf var/*

2- rm -rf pub/static/*

3- php bin/magento setup:upgrade

4- php -f bin/magento setup:static-content:deploy en_US ru_RU

5- chmod -R 777 var pub/static

6- php bin/magento indexer:reindex

Your Answer

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

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