Web scraping hotel rooms data from booking.com with Python.
- Run example.py for testing code. It will fetch hotel data from London for next day for duration of 1 night and 2 adults.
- This script uses selectorlib. Therefore Chromedriver or selenium are not required.
- Python 3.6
- Make sure to install the following libraries before you run the script. The versions specified below were used for developing the script, however it might work perfectly with a different version. Just give it a try.
requests==2.24.0 selectorlib0.16.0 pandas==1.1.3
- After the script runs a CSV file will be created named "example_output.csv" in the same folder where the script runs. The csv looks like this on excel: