Introduction to Access Blocking
In the digital age, controlling access to your website is crucial for enhancing security and optimizing user experience. Adobe Commerce, in conjunction with Fastly, provides robust options to block access by country. This capability allows you to manage traffic effectively and protect your site from unwanted visitors.
Steps to Block Access
The process to block access is straightforward. Firstly, ensure that you have your Fastly account linked with your Adobe Commerce platform. After this, you will need to configure the Geo-blocking settings. Fastly uses the Geo-location data of visitors to enforce your access rules.
To setup the Blocking/Allowing from the configuration follow the below steps:
- Logged In to Adobe Commerce Admin: Logged In with the username and password in the Admin Panel.
- Open Store Configuration: After the logged In to Admin Panel open the Store Configuration with the below path.
Admin Menu >> Stores >> Settings >> Configuration >> Advanced >> System >> Full Page Cache. - Setup Blocking: For the setup the Blocking use below path.
Full Page Cache >> Fastly Configuration >> Blocking.- Blocking Type: Select the Type “Blocking”.
- Country List: Select the countries from the list. You can select multiple countries from the list.
- Update Blocking: Once above mentioned steps done click on the Update Blocking Config.
- Blocking: Once all the setup completed click on the Enable/Disable if blocking is not Enable. (If it’s already Enable then no need to click button again.)
- Once click on the Enable button then new popup will open same like below screenshot. Once popup open click on the Enable.
If you want to do reverse like allow only for the particular countries. Follow the above same steps just need to change the Blocking Type and click on update the Blocking Config.
If you want to block particular IPs you can create the ACLs and select from the ACLs list. To create ACLs you can click here.
Once you Block counties then customers are showing the Error Page with error code but we can show good designed page. For the set the page you can follow here.
Testing Your Configuration
Once you have set up your Geo-blocking rules, it is essential to test to ensure clarity in access. Use VPN services to connect from different regions and verify that your site is appropriately blocked or accessible. This testing phase is critical to ensure that legitimate users are not inadvertently blocked.
In conclusion, blocking access by country in Adobe Commerce through Fastly is an effective method to manage your website’s security and user interaction. Implement these settings carefully and regularly review them to adapt to changing user demographics and security needs.