Site can detect headless mode
# crawlee-js
r
I have a Crawlee Playwright bot that logs into a website and performs some actions on a schedule. I made a public version here without the site or actions: https://github.com/raywalz/web-automation-starter For some reason, the website can detect headless mode despite the stealth plugin. It works fine in headed mode though. Any ideas? I have documentation on the setup in the readme of that project. I may give up and use XVFB and headed mode all the time like I’ve seen a previous post here mention, but I want to try to keep it headless if I can.
h
Someone will reply to you shortly. In the meantime, this might help: -# This post was marked as solved by foxt141. [View answer]().
f
Hi! As explained [here](https://old.reddit.com/r/webscraping/comments/1c9i4k3/is_puppeteerextrapluginstealth_still_working/) I would recommend to try something other than the puppeteer stealth plugin, for example Crawlee's [
PlaywrightCrawler
](https://crawlee.dev/docs/examples/playwright-crawler). If it doesn't work I would attempt to use
PuppeteerCrawler
- some websites are able to detect playwright, but fail with puppeteer. Also, refer to [this](https://crawlee.dev/docs/guides/avoid-blocking) guide If it still doesn't help, disabling
headless
might be necessary - from my experience some websites with advanced web-scraping protection will indeed have scripts that are able to determine that.
r
Thanks I’ll look into those. To be clear I am using Playwright, not Puppeteer. I’m just using the puppeteer-extra-plugin-stealth plugin with it. Though it has puppeteer in the name, it’s compatible with both since Playwright is just a fork.