This project is a script designed for practice purposes only to automate simple Google searches and simulate user interactions on target web pages. It utilizes Selenium WebDriver with Python and requires a Firefox browser. Be aware of the potential risks of automated queries—Google may penalize such activities. Use responsibly and only within the bounds of legal and ethical guidelines.
- Multi-Engine Support: Perform searches on Bing, DuckDuckGo, and Yahoo.
- Proxy Rotation: Automatically rotates proxies to ensure anonymity.
- User-Agent Spoofing: Randomly selects user-agents to mimic real browser activity.
- Headless Browsing: Uses headless Firefox for efficient and invisible operations.
- Cookie Handling: Automatically accepts cookie policies to prevent interruptions.
- Customizable Search Duration: Define the duration for which the bot should visit and scroll through the search results.
- GUI Support: User-friendly GUI for easy configuration and control of the bot.
- Operating System: Windows 10/11.
- Browser: Latest version of Firefox/Geckodriver.
- Python Version: Python 3.x.
Run the following commands to install dependencies:
pip install selenium-wire
pip install fake_useragent
pip install customtkinter
pip install urllib3
pip install requests
- Clone this repository to your local machine.
- Run the script using Python:
python3 main.py
- The script selects a random keyword from the predefined
keywords_with_urls
dictionary. - It launches a headless Firefox browser instance with a random user agent and window size.
- Simulates a Google search for the keyword and navigates to the associated URL.
- Performs interactions (scrolling, clicking links) to mimic human behavior.
- Repeats the process with randomized delays between sessions.
- Keywords & URLs: A random keyword and associated URL are selected for each search.
- User Agents: A random user agent is applied to each session.
- Browser Window Size: Resized to emulate various device types.
- Simulates Google searches and checks if the target URL appears in the results.
- If not found, directly navigates to the predefined URL.
- Automatically clicks on cookie and terms acceptance buttons when presented.
- Scrolls the page randomly and clicks on links to simulate user behavior.
The keywords_with_urls
dictionary stores the keyword-URL pairs:
keywords_with_urls = {
"example keyword": "https://example.com/page1",
"another keyword": "https://example.com/page2"
}
- Legal Risks: Automated web interactions may violate terms of service. Ensure you have proper authorization.
- Google Penalties: Automated queries could result in IP bans or other restrictions.
- Headless Browsing: Although this script runs in headless mode, detection mechanisms may still recognize automation.
Feel free to submit issues or contribute enhancements via pull requests.
For business inquiries, reach out to:
Kristian Gasic
📧 kristian@gasic.bio