Skip to content
← Back to Community
Open google homepage with python
Profile icon
[deleted]

How do you open the google homepage with python 3? I keep trying, but nothing ever happens. (Probably because I use chrome) How do I open it? Is it even possible? Here is a repl with a code I got from here: https://pythonprogramming.altervista.org/how-to-open-a-web-page-in-the-browser-using-chrome-with-python-and-webbrowser/?doing_wp_cron=1591463598.7557270526885986328125

Answered by SystematicError [earned 5 cycles]
View Answer
Voters
Profile icon
KhaledKhadra
Profile icon
DeanGijohn
Profile icon
TannerCorona
Profile icon
AidanFelch
Comments
hotnewtop
Profile icon
SystematicError

Hey @CarlosRosiles,
Try to use the webbot library like this:

import webbot web = webbot.Browser() web.go_to('http://pythonprogramming.altervista.org')

Please upvote if this helped and/or mark this as the answer if it worked for you @CarlosRosiles!

Profile icon
[deleted]

@SystematicError It worked!

Profile icon
SystematicError

@CarlosRosiles, Glad I could help!
Btw, I tried to look up webbrowser on PyPI.org and its not available, I think is an in-built Python package so if you want to use your webbrowser package you can go to https://docs.python.org/3/library/webbrowser.html

Profile icon
NighlaMiller

r