> From the [Strife developer docs](https://strife.app/docs/reference/fields/file). Every page is listed in [llms.txt](https://strife.app/docs/llms.txt).

# File~

<figure><img src="https://strife.app/docs/assets/Screenshot%202023-10-27%20at%2011.18.48.png" alt="" width="375"><figcaption><p>Strife Studio screenshot of a File field</p></figcaption></figure>

> [!WARNING]
> The tilde (**\~**) denotes that the field is available in developer preview only.

### Settings

In addition to the basic settings, this section provides information about unique settings and configurations specific to this field.

> [!NOTE]
> You can find a comprehensive list of all basic settings in the ['Overview' section](https://strife.app/docs/reference/fields.md).

<table><thead><tr><th width="182">Option</th><th>Description</th></tr></thead><tbody><tr><td>Restrict types</td><td>Restrict the allowed types to upload in the File field</td></tr></tbody></table>

### Define with JSON

When defining templates using JSON, this field is represented using:

* **Component Name:** `str-file`
* **Type:** `file`
* Reference ID: `str-file`

The settings above map into the `editor.attributes` object inside the JSON definition.

```json
{
  ...
  "editor": {
    "name": "str-file",
    "type": "file",
    "propertyName": "...",
    ...
    "attributes": {
      "allowedTypes": "..."
    }
  },
  ...
}
```

### Live preview

> [!NOTE]
> This field does not have any default Strife Web Components. Custom live preview implementations are fully supported.

> [!NOTE]
> For more information on live preview and Strife Web Components, please refer to the [Live preview documentation](https://strife.app/docs/reference/live-preview.md).
