There are a lot of practical uses for automating user behavior in a browser. Everything from testing your web application to logging into Twitter and auto following people.
But first you have to install the tools. Here is everything you need to run your scripts.
First install selenium with pip
pip install selenium
Next download Firefox. Visit https://www.mozilla.org/firefox and download and install.
Next you'll need the geckodriver
brew install geckodriver
That's it. Now you can run your Python scripts.
from selenium import webdriver
browser = webdriver.Firefox()
browser.get('https://google.com')
Click here for more information on Selenium and access to the full API
There is also a detailed guide to using the Selenium IDE over at the GURU99 Website: https://www.guru99.com/first-selenium-test-script.html
Just finishing up brewing up some fresh ground comments...