Skip to main content

def open(
url: str,
is_maximize: bool = True,
is_wait_complete: bool = True,
userdata_folder_mode: Literal["automatic", "default", "custom"] = WebUserDataMode.Automatic,
userdata_folder_path: str = "",
timeout: int = 30
) -> BrowserTab

Open browser with specified url to get a browser tab. Browser automation extensions should be installed and enable. CDP is supported for Chrome and Edge browser, chromecdp and edgecdp can run without browser automation extension.


  • When you open and run the Python script with "Start Debugging (F5)" or "Run Without Debugging (Ctrl+F5)" in Visual Studio Code , the opened browser may be closed when exiting the debugging or running state.
  • CDP doesn't support attach existing browsers.

url[Required]: str
Url string, the target site url, eg.:
is_maximize: bool
is_maximize, whether to maximize the browser window, the default value is True.
is_wait_complete: bool
is_wait_complete, whether to wait for the broswser to complete loading, the default value is True.
userdata_folder_mode: WebUserDataMode
userdata_folder_mode defines whether using customized user data folder when opening the browser.
automatic:use user data folder automatically.
default:use default folder of the user data.
custom:use the folder specified by parameter 'userdata_folder_path'.
userdata_folder_path: str
User data's folder path.
timeout: int
Timeout for the operation, the unit is second, and the default value is 30 seconds.

BrowserTab object, you can execute the following operations in the browser tab such as: find_element, find_elements, close, refresh and so on.


from clicknium import clicknium as cc

# open IE browser
ie_tab ="")

# open Chrome browser
chrome_tab ="")
# open Chrome browser with CDP
chrome_tab ="")

# open Edge browser
edge_tab ="", is_wait_complete = True)
# open Edge browser with CDP
edge_tab ="", is_wait_complete = True)

# open Firefox browser
firefox_tab ="", timeout = 10)