using Magento 2.2.2, I have a store with two views English and French,
I want to make urls looks like
domain.com/en/product1 domain.com/fr/category1
...
thanks
In Admin -> Store -> All Stores
, make sure the store view codes are set as English = en
and French = fr
.
And in Admin -> Store -> Configuration -> General -> Web -> URL Options -> Add store code to URLs