Close JavaScript Popup Window In Selenium WebDriver Leave a Comment / Webdriver Tutorial / Windows Handler When you open a webpage, you may find a lot of popup windows. How to close those popups in selenium automation test script? You can achieve that by using Windows Handlers API in selenium webdriver.