Troubleshoot Form Authentication


When testing logged in pages, there might be cases in which the authentication is not successful. This article lists the common reasons for form authentication failure and explains how to fix them.

If Calibre cannot find the form on the page, the test will either fail or result in the form URL being monitored instead of the logged in page. The Authentication Log on the Snapshot Overview report will display an error and list selectors which weren’t found, to help with setting up authentication successfully:

Authentication log showing failure with 'input unable to be filled in: iinput[type='password']'

Choose correct selectors

To ensure authentication succeeds, use form and input selectors with high specificity, such as id or name.

✅ Recommended🚫 Not recommended

Selectors with high level of specificity, such as:

  • #sign-in-form
  • #login
  • #username
  • input[name="username"]
  • input[type="password"]

General selectors that might return multiple matches, such as:

  • form
  • input
  • body
  • html
  • div
  • section

Elements must be visible and within the main document

For Calibre to successfully navigate HTML forms, form elements must meet the following prerequisites:

  • Elements should not be visually obstructed (hidden off-screen or using CSS opacity with value less than 1)
  • Elements must appear within the main document (e.g., not nested within an <iframe>)
  • Elements must respond to event handlers (e.g., click or submit)

Use semantic HTML markup

Calibre searches for a specified Submit selector first. If the selector is not found or not provided, the Test Agents will fall back to looking for valid HTML markup to submit the form and begin monitoring. A valid submission button should have one of the following characteristics:

  • be a button element.
  • have ARIA button role (role="button).
  • have the type of submit.

Non-semantic markup and multiple elements fulfilling the above requirements might cause failed tests. Calibre scans your Sites for submission buttons in the following order:

  1. Selector provided in Submit selector field
  2. [type="submit"]
  3. [type='submit'][value='Sign in']
  4. [type='submit'][value='Next']
  5. [type='button']
  6. button
  7. [role='button']