Hi @sonu rajput
Do you use Edge browser? If yes, you can refer to the following code sample. Please note that change the Edge WebDriver path and Profile path to your owns. Please kill all existing Edge instance before you execute the code:
from selenium import webdriver
from selenium.webdriver.edge.service import Service
from time import sleep
ser = Service("E:\\webdriver\\msedgedriver.exe")
edge_options = webdriver.EdgeOptions()
edge_options.use_chromium = True
edge_options.add_argument("user-data-dir=C:\\Users\\Administrator\\AppData\\Local\\Microsoft\\Edge\\User Data")
edge_options.add_argument("profile-directory=Profile 1")
driver = webdriver.Edge(service = ser,options = edge_options)
driver.get('https://www.bing.com')
sleep(20)
You can find the profile path in edge://version/:
If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.
Regards,
Yu Zhou