how to open new window in selenium code example Example: open new window in selenium driver.execute_script("window.open('https://twitter.com')")