> For the complete documentation index, see [llms.txt](https://wiki.4thtech.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://wiki.4thtech.io/sdk-and-white-label/storage-1/remote-storage-provider/upload.md).

# upload

{% hint style="info" %}
Reference for SDK 0.5.x (maintenance mode). See [Status](/sdk-and-white-label/status.md).
{% endhint %}

Upload a file to a remote storage provider.

### Usage

```ts
const uploadedFileUrl = await myRemoteStorage.upload(file, fileName);
```

### Returns

`Promise<string>`

A promise that resolves to the URL of the uploaded file.

### Parameters

#### file

* **Type** `FileInput`

The file data that you want to upload.

#### fileName (Optional)

* **Type** `string`

The name you want to give to the uploaded file.
