<Directory "/var/www"> SetEnvIfNoCase User-Agent ".*(FeedDemon|JikeSpider|YandexBot|AskTbFXTV|AhrefsBot|CrawlDaddy|Java|Feedly|UniversalFeedParser|ApacheBench|Swiftbot|ZmEu|oBot|jaunty|Python-urllib|lightDeckReports Bot|YYSpider|DigExt|YisouSpider|HttpClient|MJ12bot|heritrix|EasouSpider|Ezooms|Barkrowler|archive|coccocbot|SemrushBot|HeadlessChrome|Sogou|GrapeshotCrawler).*" BADBOT Order allow,deny Allow from all deny from env=BADBOT </Directory>