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

# Upload File

> Upload a local file to the QuickBlox cloud storage. The request is a multipart HTTP request where one part is a JSON object and the other part is the content of the file itself.

To upload a file, proceed as following:

1. [Create File](/reference/create-file). Make sure to create an entity for a file within the system - a blob, **before** uploading it.
2. Upload File. An upload link is obtained from the response to the [create file](/reference/create-file) request. The link has expiration time so if it gets expired, you should obtain a new link using the create file request.

**File size limit**

The maximum size of the uploaded file depends on the membership plan.

|                 | Basic | Startup | Growth | HIPAA | Enterprise                                                      |
| --------------- | ----- | ------- | ------ | ----- | --------------------------------------------------------------- |
| File size limit | 10 Mb | 25 Mb   | 50Mb   | 50Mb  | [Contact our sales team](https://quickblox.com/enterprise/#get) |

#### Path Parameters

<ParamField path="blob_id" type="integer" required>
  ID of the file/blob. Generated automatically by the server after file/blob creation.
</ParamField>

#### Body Parameters

<ParamField body="file" type="string" required>
  A binary file to be uploaded to the cloud storage. The file size is restricted by the membership plan.
  See the [File size limit](/reference/content#file-size-limit) section below.
</ParamField>

<ParamField body="key" type="string" required>
  File/blob identifier that should be taken from the response of the Create File request. This is the UID parameter.
</ParamField>

#### Responses

<AccordionGroup>
  <Accordion title="201">
    A successful response
  </Accordion>

  <Accordion title="400">
    An error response
  </Accordion>
</AccordionGroup>

<RequestExample>
  ```bash cURL theme={null}
  curl -X POST 'https://api.quickblox.com/blobs/10070416/upload/' \
  -F 'key=20456a9676674f4ca950d963dfca630e00' \
  -F 'file=@/Users/test/Downloads/33.jpg'
  ```
</RequestExample>

<ResponseExample>
  ```json 201 theme={null}
  Empty body
  ```

  ```json 400 theme={null}
  {}
  ```
</ResponseExample>
