DEV Community

Mohamed Irsath
Mohamed Irsath

Posted on

To bypass cloudfare pop up

Image descriptionI am accessing the ahrefs website to view the domain ranking of a website by entering the website name in a search box.I am doing this for multiple sites at the same time via selenium.When the code gets running,I am getting the Cloudfare pop up to verify whether it is a human or not before showing the search results. Can someone please help me to fix this in Selenium Java ?

Top comments (3)

Collapse
 
mohamed_irsath_0f7d5629ed profile image
Mohamed Irsath

@dogers I tried all the ways to control the site by using chrome options,opening dev tools & refresh the browser multiple times,i did not get the success out of it. If you know any workaround for it,please share me the solution

Collapse
 
dogers profile image
Dogers

No I mean control as in own it - you'd need to use the backend URL rather than the one fronted by Cloudflare. I'm sure there's probably bodges people have made to get round it, but fundamentally it's designed to stop this type of access so will break as they fight back and update.

Collapse
 
dogers profile image
Dogers

Just click the box :D
The whole point of the check is to block scripting - if you don't control the site, then there's no reliable workaround for it.