Magento Extension

BadBot Protection for Magento 2

Stop scanners, price scrapers, spam bots and fake Googlebots with a browser check that runs on your own server. Real customers and good bots pass as usual. No account needed, and no visitor data leaves your store.

Last Update: 19 Oct 2026
Version: 5.0
Compatibility: Magento Open Source and Adobe Commerce 2.4.7 to 2.4.9 / PHP 8.2 and newer
Price: Free

Unpack the archive in the Magento folder and run bin/magento setup:upgrade.

Why bots matter

Most of the traffic of a typical online store is not people. Vulnerability scanners look for holes in your extensions, scrapers copy your prices and product descriptions, spam bots fill your contact, review and newsletter forms, and password guessers try your customer and admin logins. They slow the store down for real customers and put it at risk. BadBot Protection tells them apart from people and from the good bots you want, and stops them before they cost you server time.

What it does

  • Browser check on your own server. Visitors that do not look like a normal browser get a short check page. The browser solves a small calculation in about a second and gets a pass; bots stay outside. Smart mode checks only suspicious visitors, All visitors mode checks everyone once a day during an attack, and Log only mode shows what would be blocked.
  • Verified search engines. Google, Bing, Apple, DuckDuckGo, Yandex, Baidu and others are checked against their official address lists or by reverse DNS. Real crawlers pass; scrapers that only pretend to be Googlebot are blocked.
  • Bot categories. Allow, check or block search engines, link previews, uptime monitors, AI assistants, AI training crawlers, SEO tools, vulnerability scanners, HTTP libraries and unknown bots.
  • Block AI training crawlers with one click. GPTBot, ClaudeBot, Common Crawl, Bytespider and other training crawlers get blocked, while AI search assistants that send visitors stay allowed.
  • Traps for scanners. Requests for files no visitor ever opens (database tools such as phpMyAdmin and Adminer, known web shells, secret files such as .env) and a hidden trap link ban the client for the time you choose.
  • Form protection. Customer login (the page and the checkout pop-up), registration, forgotten and reset password, the contact form, product reviews, newsletter subscription, Email to a friend and the admin login accept posts only from a real browser. People notice nothing; spam bots and password guessers are refused. Checkout is never touched.
  • Allow and block lists. IP addresses (IPv4, IPv6, CIDR), User-Agents, and URLs that never get the check.
  • Activity and statistics. Charts for 24 hours, 7 and 30 days, the top bots, addresses, pages and reasons, and a log of recent events.
  • Your check page. Your logo and texts, with a live preview.
  • Safe for your store. Logged-in customers and admins are never checked. The protection runs before Magento's built-in page cache, so cached pages are protected too. The REST, SOAP and GraphQL APIs and payment notifications are not checked. An emergency switch file turns everything off.

Screenshots

Private by design

Bot detection, the browser check and the statistics all run on your server. The extension does not send visitor data anywhere and needs no account or connection to an outside service.

Full website protection

BadBot Protection stops bad bots. SiteGuarding protects the whole website. Block unwanted bots is part of the SiteGuarding Premium and Business plans, together with:

  • Website Firewall (WAF): SQL injection, XSS and exploit blocking
  • Server-side antivirus and daily malware scanning
  • Hack repair by our experts
  • DDoS prevention
  • Brute force and card testing protection
  • GEO blocking
  • 24/7 monitoring, website backups and an SSL certificate

FAQ

Will it hurt my search ranking?

No. Google, Bing and other search engines are verified by their official addresses and never see the check. If a crawler cannot be verified, it gets a temporary "try later" answer, never a block.

What do real customers see?

In Smart mode almost all of them see nothing. In All visitors mode each new visitor sees the check page for about a second, once per day by default.

Will it affect checkout and payments?

No. Checkout is not a protected form, and payment notifications and the REST, SOAP and GraphQL APIs are never checked.

How do I install it?

Unpack the archive in the Magento folder, then run bin/magento module:enable Siteguarding_Antibot, bin/magento setup:upgrade and bin/magento cache:flush (in production mode also setup:di:compile and setup:static-content:deploy). The protection starts in Smart mode at once; the settings are in SYSTEM > Other Settings > BadBot Protection.

I use version 1.1. How do I update?

Unpack 5.0 over it and run the same commands. Version 5.0 removes the old check of 1.1 from .htaccess and .user.ini, moves the old files away, keeps copies of everything, and adds the addresses of your 1.1 lists to the new Lists screen.

Does it work with Cloudflare, Varnish and the page cache?

Yes. Cloudflare is detected automatically, and other proxies can be added in the settings. Magento's built-in page cache is no problem: the check runs before it. A Varnish server or a CDN that answers from its own cache does not ask Magento, so those requests are not checked.

Does it send data anywhere?

No. Everything runs on your server. Only the BadBot Protection page in your admin asks siteguarding.com for the number of the latest version.

I locked myself out. What now?

Create an empty file named sgbb-off.txt in the Magento folder (next to app/ and bin/), with SSH, FTP or the file manager of your hosting. The protection stops at once. Delete the file to turn it back on.

Changelog

5.0
- New version on the same core as the WordPress, Joomla, OpenCart and Drupal editions.
- Browser check on your own server, with Smart, All visitors and Log only modes.
- Verified search engines by official addresses and reverse DNS; fake crawlers are blocked.
- Bot categories, including AI assistants and AI training crawlers.
- Traps for scanners, hidden trap link and bans.
- Protection for customer login (page and checkout pop-up), registration, forgotten and reset password, contact, product reviews, newsletter, Email to a friend and admin login forms.
- Works with IPv6 visitors, before the built-in page cache, with logged-in customers and admins never checked.
- Allow and block lists, excluded URLs, activity charts and log.
- Replaces version 1.1 on update and keeps its lists.
- Magento Open Source and Adobe Commerce 2.4.7 to 2.4.9.

Live Chat Support
Our website uses cookies, which help us to improve our site and enables us to deliver the best possible service and customer experience. See our policy Accept