We have multiple stores. How can we apply store wise CSS? We have all store has a different home page and all pages.

I am thinking to add store code in body class to identifies store.


<body data-container="body" class="<store-code> customer-account-login page-layout-1column ajax-loading" aria-busy="true">

Is it a proper method?

  • You need to create child level themes for all the stores, and make your current theme as parent.
  • Select each child level theme to each store
  • Now you don't need to copy all the files to every theme, just use different css with the same name in all the themes like styles.less or styles.css

This will use different css files for each theme. This is the way of Magento 2

  • Thanks. It's working properly. – Ravi Soni Jun 19 '19 at 9:48
  • Good to hear that. Welcome. +1 for appreciation :) – Shoaib Munir Jun 19 '19 at 9:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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