Open a browser URL using Python

import modules

import webbrowser

create dummy dataframe

#select the url you want to open
url = ''
#set browser path
chrome_path = 'open -a /Applications/Google\ %s'
#open browser, search URL

Your browser should open after running the above.
Your Chrome path may vary, so if you need to debug I would recommend starting there.

Ace your next data science interview

Get better at data science interviews by solving a few questions per week

Learn more

Find a bug? Submit a suggested change on Github, or message me on Twitter.