google
finds my browser is being manipulated/controlled/automated
by software, and because of that I get reCaptcha
. When I manual start chromium and do the same steps the reCaptcha doesn't appear.
Question 1)
Is it possible to solve captcha Programmatically or get rid of it when using puppeteer
? Any way to solve this?
Question 2)
Does this happens only when without headless
option i.e
const browser = await puppeteer.launch({ headless: false })
OR this is something the fact we have to accept and move on?
In short, yes they can. While reCAPTCHA v2 and v3 can help limit simple bot traffic, both versions come with several problems: User experience suffers, as human users hate the image/audio recognition challenges. CAPTCHA farms and advances in AI allow cybercriminals and advanced bots to bypass reCAPTCHAs easily.
Puppeteer is a Node library which provides a high-level API to control headless Chrome or Chromium over the DevTools Protocol. It can also be configured to use full (non-headless) Chrome or Chromium. An explanation of what Puppeteer is and the things it can do.
Try generating random useragent using this npm package. This usually solves the user agent-based protection.
In puppeteer pages can override browser user agent with page.setUserAgent
var userAgent = require('user-agents'); ... await page.setUserAgent(userAgent.toString())
Additionally, you can add these two extra plugins,
puppeteer-extra-plugin-recaptcha - Solves reCAPTCHAs automatically, using a single line of code: page.solveRecaptchas()
NOTE: puppeteer-extra-plugin-recaptcha
uses a paid service 2captcha
puppeteer-extra-plugin-stealth - Applies various evasion techniques to make detection of headless puppeteer harder.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With