VLearnVibium

How to Automate a Login Flow with Vibium

Step-by-step guide to automating a website login with Vibium in Python — find the fields, type credentials, submit, and verify the result.

By Pramod Dutta··1 min read·Verified with Vibium 26.2
▶ Animated overview · made with Remotion

To automate a login with Vibium: open the login page, find() the username and password inputs, type() the credentials, click() submit, then verify the result. Vibium auto-waits for each element, so you don't need manual sleeps.

The full login script

from vibium import browser_sync as browser
 
vibe = browser.launch()
vibe.go("https://app.example.com/login")
 
email = vibe.find('input[id="login-username"]')
email.type("user@example.com")
 
password = vibe.find('input[id="login-password"]')
password.type("secure-password")
 
submit = vibe.find('button[id="login-btn"]')
submit.click()
 
vibe.quit()

Step by step

  1. Open the pagevibe.go(url) navigates and waits for load.
  2. Find the fieldsvibe.find(css) returns an element. Vibium waits until it's actionable (visible, enabled) before you interact.
  3. Type credentialselement.type("...") enters text like a real user.
  4. Submitelement.click() on the login button.

Verify the login worked

After submitting, read an element that only appears when logged in (or an error message on failure):

error = vibe.find('div[id="login-error"]')
print(error.text())

Tip: keep credentials out of your code — read them from environment variables (os.environ["APP_PASSWORD"]) so you never commit secrets.

Next steps

Frequently asked questions

How do I automate login with Vibium?

Navigate to the login page, find the username and password inputs with find(), type() the credentials, click the submit button, then read the page to verify success.

How does Vibium find form fields?

Use vibe.find() with a CSS selector (for example an input id or name). Vibium auto-waits for the element to be actionable before interacting with it.

Vibium is created by Jason Huggins. This is an independent tutorial — see the official Vibium site and GitHub repo for canonical docs.

Related guides