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

# UploadFileAction

> Upload file to interactive element with file path

> [!TIP]
>
> Read [the Notte skill](https://notte.cc/skill.md) and follow its setup instructions when setting up Notte or building browser automation. This is the shared source for CLI setup, authentication, and the browser-to-code workflow.

Use with any upload file element, including button, input, a, span, div. CRITICAL: Use only this for file upload, do not use click.

In cloud sessions, `file_path` accepts a session file's filename or a public HTTP(S)
file URL, including signed URLs. URL files are downloaded on the API server and
attached without navigating away from the form. Downloads do not use browser
cookies, browser proxy settings, or custom authentication headers. They are
temporary and are not added to the session's persistent file catalog.

URL support requires the cloud backend feature; it does not require an SDK update.
Standalone local sessions retain their existing storage/path behavior and do not
gain URL downloading. To use a local file with a cloud session, first upload it
with `session.storage.upload()` and pass the returned filename.

**Example:**

```python theme={null}
# Cloud session: attach an existing session file by filename.
session.execute(type="upload_file", selector='input[type="file"]', file_path="document.pdf")
# Cloud session: download and attach a public or signed HTTP(S) URL.
session.execute(
    type="upload_file",
    selector='input[type="file"]',
    file_path="https://example.com/document.pdf",
)
```

## Fields

**type** `Literal['upload_file']` (default: upload\_file)

**category** `str` (default: Interaction Actions)

**description** `str` (default: Upload file to interactive element with file path. Use with any upload file element, including button, input, a, span, div. CRITICAL: Use only this for file upload, do not use click.)

**id** `str`

**selector** `str | NodeSelectors | None`

**press\_enter** `bool | None`

**text\_label** `str | None`

**accessible\_name** `str | None`

**param** `ActionParameter | None` (default: name='file\_path' type='str' default=None values=\[])

**timeout** `int` (default: 15000)

Action timeout in milliseconds

**file\_path** `str` *required*

## Module

`notte_core.actions.actions`


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.