from selenium import webdriver from selenium.webdriver.chrome.options import Options options = Options() options.add_argument("--proxy-server={}".format("127.0.0.1:12345")) driver = webdriver.Chrome(executable_path="webdriver.exe", options=options)