Magento – Your session has expired main home page magento 2

magento-2.1magento2magento2.3.0

Go to home page and add to cart product and then this time error is come Your Session Has Expired
I also try to change pen PHPMYADMIN
run:
UPDATE core_config_data SET value = 864000 WHERE path = 'admin/security/session_lifetime' but not working tell me how to find this solution

Best Answer

Maybe you are using localhost instead of 127.0.0.1.
Run below two lines in console:

php bin/magento setup:store-config:set --base-url="http://127.0.0.1/"
php bin/magento setup:store-config:set --base-url-secure="https://127.0.0.1/"
Related Topic