> ## 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.

# authSave

> Save the current browser auth state to a Playwright storage-state file.

Pairs with `authLoad`. Defaults to the path configured by the containing auth
module. The bare scalar `- authSave` saves to the default path.

## Parameters

| Parameter | Type      | Required | Description                                                           |
| --------- | --------- | -------- | --------------------------------------------------------------------- |
| `path`    | `string`  | No       | Path to write the storage-state JSON file to.                         |
| `saveAs`  | `string`  | No       | Name of the variable to write this step's return value to.            |
| `retries` | `number`  | No       | Number of times to retry the step on failure before failing the test. |
| `skipped` | `boolean` | No       | Skip this step at execution time.                                     |

## Shorthand

Bare command. Saves to the default path.

```yaml theme={null}
- authSave
```

## Examples

```yaml theme={null}
- authSave: ./auth-state.json
```

```yaml theme={null}
- authSave:
    path: ./auth-state.json
```

## Related

* [Authentication](/core-concepts/authentication)
* [Test format](/core-concepts/test-format)
