Python chess bot that plays chess online on chess.com using Stockfish Engine
- Compatible with Python 3
-
Install python3
-
Install python dependencies:
pip install -r requirements.txt
-
Selenium requires a driver to interface with the chosen browser. Firefox, for example, requires geckodriver, which needs to be installed before the below examples can be run. Make sure it’s in your PATH, e. g., place it in /usr/bin or /usr/local/bin. Download geckodriver here.
- Python 3:
python3 chessbot.py
Note: Before running ChessBot, enable the premove and auto-queen option in chess.com settings. If ChessBot is running slow on your computer, lower the number of threads for stockfish engine.
The code for this project is written with goodwill and not to harm anyone. This is purely for educational purposes. I am not responsible or take liability for the consequences of anyone using this code.
CAUTION: Use it on your own risk, as using ChessBot could get you banned.