How to select a drop-down menu value using Selenium in Python? Last Updated : 11 Oct, 2020 Summarize Comments Improve Suggest changes Share Like Article Like Report Prerequisite: Browser Automation Using Selenium Selenium is an effective device for controlling an internet browser through the program. It is purposeful for all browsers, works on all fundamental OS and its scripts are written in numerous languages i.e Python, Java, C#, etc, we will be using Python. Requirement: You need to download install chrome driver from here Click Here and set path. Working with Drop-down list: Initially you have to import the Select class and afterward you have to make the case of Select class. After making the case of Select class, you can perform select strategies on that occasion to choose the choices from dropdown list. Importing Select class: from selenium.webdriver.support.ui import Select For selection: drop=Select(driver.find_element_by_id(' ') drop.select_by_value(" ") Step-by-step approach: Import webdriver from selenium module. Python3 # Import required module from selenium import webdriver Import Select class module. Python3 # Importing Select class from selenium.webdriver.support.ui import Select Using a web page for drop down list(example: URL).Navigate the id of option bar.Navigate options value in html web page. Below is complete program of the above approach: Python3 # Import required module import time from selenium import webdriver # Import Select class from selenium.webdriver.support.ui import Select # Using chrome driver driver = webdriver.Chrome() # Web page url driver.get("https://fs2.formsite.com/meherpavan/form2/index.html?1537702596407") # Find id of option x = driver.find_element_by_id('RESULT_RadioButton-9') drop = Select(x) # Select by value drop.select_by_value("Radio-0") time.sleep(4) driver.close() Output: Comment More infoAdvertise with us Next Article How to click a button on webpage using Selenium? P praveeny182 Follow Improve Article Tags : Python Python-selenium Practice Tags : python Similar Reads Select Drop-down list using select_by_index() in Selenium - Python Prerequisite: Browser Automation Using Selenium Selenium is an effective device for controlling an internet browser through the program. It is purposeful for all browsers, works on all fundamental OS and its scripts are written in numerous languages i.e Python, Java, C#, etc, we will be using Python 2 min read Selecting a drop-down list by using the Selenium.select_by_visible_text() method in Python Selenium is an effective device for controlling an internet browser through the program. It is purposeful for all browsers, works on all fundamental OS and its scripts are written in numerous languages i.e Python, Java, C#, etc, we can be running with Python. Different methods of Select class: Selec 2 min read How to Locate Elements using Selenium Python? Selenium: is an open-source tool that automates web browsers. It provides a single interface that lets you write test scripts in programming languages like Ruby, Java, NodeJS, PHP, Perl, Python, and C#, among others. I personally prefer Python as itâs very easy to write code in python. A browser-dri 3 min read How to click a button on webpage using Selenium? This article is all about how to click any button using Selenium on a webpage and many more concepts related to the same which are discussed below. Table of Content What is Selenium? How to click on a button using Selenium Conclusion Frequently Asked Questions on How to click a button on webpage usi 2 min read How to get text of a tag in selenium - Python? Selenium is a powerful tool for controlling web browsers through programs and performing browser automation. It is functional for all browsers, works on all major OS and its scripts are written in various languages i.e Python, Java, C#, etc, we will be working with Python. In this article, we will w 1 min read How to handle alert prompts in Selenium Python ? Seleniumâs Python Module is built to perform automated testing with Python. Alerts are a way to show popups in the browser for either accepting data or displaying data. Selenium provides methods to handle alerts of all kinds. Seleniumâs Python Module is built to perform automated testing with Python 2 min read Like