Every Magento installation has a hierarchy of websites, stores, and store views. Websites, stores and store views have one too many parent child relationships.But, first of all, let's add some simple data to our site because we don't have any categories, products or even content pages.So let's do it. To do it, we have to run the following shell script - ... bin ... magento ... sampledata ... deployThen we have to run bin/magento setup:upgrade script, which will add all the necessary data.So let's do it.As you can see, we have some additional categories and products.This is all the necessary data to set up the store hierarchy.Let's switch to the store structure.Website, stores and store views. Websites!Magento Installation begins with a single website, which by default is called Main website.You can also set up multiple websites for a single installation, each with its own domain. StoreA single website can have multiple stores, each with its own main menu.The stores share the same product catalog, but can have a different selection of products and design.Store on the same website share the same admin and checkout. Store views! Each store that is available to customers is presented according to specific view.Initially, a store has a single default view. Additional store view can be added to support different languages or for other purposes.For example: customers can use the language selector in the header to change the store view. Let's create a store structure and to do this let's go to the admin panel.We have to go to the stores menu and click all stores link. Website!Website is a top-level container for sites. So to create completely separate site that do not share cart, shipping methods, or other you must create separate websites.So let's create some website. For example, Europe and United States.Website contains at least one store, so multiple stores can share cart, user sessions, payment gateways and more.But, they have separate catalog structure and catalog price.So let's create store!One store for Europe website and one store for United States website.As you can see, we can define root category per store, so let's create additional root category.So now we can use these root categories for our new stores.And finally Store views!Store views change the way pages are presented and are typically used to display a store with different layouts or languages you can actually manage different currencies per store view.So let's create one store view for Europe and one store view for United States.Now we can define base currency for each web site.So let's do it. To do this we have to go to Stores menu and click configuration link.And in the General section we have a currency settings.But as you can see, we have to change the price scope in catalog -> price -> catalog price scope.Let's find it.Catalog ... Catalog ... Price ... Catalog Price ScopeLet's switch it to website and click Save.Now we can define base currency on the website level and As you can see, each configuration has a scope.The term "scope" defines where in the store hierarchy an object such as a product, attribute, category, or even a content element or configuration setting applies.Now we can switch between scopes. We can define some configuration value on this level. Website, Store or Store View. For example, only on website level we can define base currency.Let's switch to Europe store.Go to General section ... and Currency Setup configuration. Now we can define base currency for Europe website.For example - euro.And let's switch to default currency for euroAnd let's find euro, and United States dollar and let's click save.OK, now we can change base currency for United States scope.But as you can see, United States scopes using default values, so we don't need to change anything here.As you can see, each configuration has its own scope, so we can define this configuration on store view level, but this one only on website level.We can define different domain names on store view level.Let's check it under General. Web. We can define different base URL and secure base URL with HTTPS. But it's not enough to configure it in admin panel.In addition, we have to create a virtual host to load many websites or one virtual host per Magento website or store view.And we have to add additional configuration to Apache or Nginx or probably make some changes to index.PHP file.But Magento provides a simple way to do it.We can enable the following settings, Under default scope we have additional configuration "Add Store Code to URL's",Let's enable it.OK!And let's add some additional configuration to see difference between store views.For example, we can define different languages for Europe store view. It can be Germany and different weight unit.And let's add some categories to see the difference between stores.Let's add "Men" category to Europe category and "Women" to United States store.As you can see, we have to clear the cache.And now we can add store view code to the URL, and we will see different store views by different URL's.Let's check it.This is United States with this structure and and this is Europe store view.As you can see, it has another currency. Let's check it.Let's open some product.So as you can see, we can define in which particular website this product is available, so it can be really useful when you create complex structure of stores, websites and store views.So now you can see how you can use website, store and store views!