---
title: "Get email link in a web test"
sidebarTitle: "Get email link"
description: "Follow a link sent by email during a web test: account confirmation, password reset, magic login. The AI picks the link you describe."
lastUpdated: "2026-09-23"
---

> **For AI agents:** the complete documentation index is at [llms.txt](/llms.txt). Append `.md` to any page URL for its markdown version.

Follow an email link as part of the flow: account confirmation, password reset, magic login. The step waits for the email, asks the AI for the link matching your intent, and stores it in a variable. Open it with a [Navigate to URL](/tests/actions/web/navigatetourl) step to continue the scenario.

## Parameters

| Parameter | Required | Description |
| ----------- | ---------- | ------------- |
| Email to receive link | Yes | The test mailbox address that should receive the email containing the link. |
| Variable | Yes | Name of the variable that receives the link. Default: `MailLink`. |
| Intent | No | Which link the AI should extract. Default: `The first link in the text`. |
| Ignore error on this step | No | The run continues with the next step if no link is found. Default: off. |

Use the intent to disambiguate emails with several links: "The password reset link", "The link in the Confirm my account button".

## Results and metrics

- **Variable**: the extracted link is stored in the variable. Open it with a navigation step to continue the flow.
- **Timing**: start, end, and duration (in seconds). The duration includes waiting for the email to arrive.
- **Status**: failed if no email arrives or the AI finds no link matching the intent.
- **AI usage**: the AI cost of the extraction is added to the run.

See [Email & SMS in tests](/tests/email-sms) for how test mailboxes work.

## What's next?

<Columns cols={2}>
  <Card title="Navigate to URL" icon="globe" href="/tests/actions/web/navigatetourl">

    Open the extracted link and continue the flow

</Card>
  <Card title="Email & SMS in tests" icon="envelope" href="/tests/email-sms">

    How test mailboxes work

</Card>
</Columns>
