> ## Documentation Index
> Fetch the complete documentation index at: https://momentic.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Download files

> Wait for a file download triggered by a **Click** step and optionally save the URL for later use.

Capture a file your app downloads when a step clicks a button or link, and
optionally save its URL to reuse later in the test (for example, to feed into an
upload step).

## Setup

1. Add a **Click** step on the button/link that triggers the download.
2. Enable **Wait for download** on that step.
3. (Optional) Set **Save to environment variable** to capture the file URL (e.g.
   `DOWNLOADED_FILE`). You can then pass `file://{{ env.DOWNLOADED_FILE }}` to a
   later [upload step](/guides/page-interactions/upload-files).

## Limits

* One file per **Click** step.
* Download timeout: 10 seconds.
* Maximum file size: 50MB.
* Downloads are deleted after each session or after 15 minutes.
* Direct file manipulation (reading contents, checking format) is not supported.

## Related

* [Upload files](/guides/page-interactions/upload-files)
