---
title: "Upload Document To Editor"
method: POST
path: "/v1/documents/upload"
tags: ["v1", "documents"]
---

# Upload Document To Editor

`POST /v1/documents/upload`

## Request

- Base URL: `https://api.superdocs.app`
- URL: `https://api.superdocs.app/v1/documents/upload`
- Auth: HTTP bearer

Upload a document file and load it into the editor.

Converts the file to HTML with formatting preserved (tables, colors, images).
Images are extracted to cloud storage and referenced by URL.
Returns the HTML for the editor to display.

AI indexing happens automatically on the first chat message.
For API clients who want immediate indexing, pass ?index=true.

## Query parameters

- `index` string, nullable: Set to 'true' for immediate AI indexing (API clients). Default: conversion only.

## Headers

- `authorization` string, nullable

## Response `200`

Successful Response

- unknown

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/superdocs/apis/universal-document-ai-api.md) · [All operations](https://skmtc.dev/superdocs/apis/universal-document-ai-api/llms.txt) · [OpenAPI document](https://skmtc.dev/superdocs/apis/universal-document-ai-api/revisions/37d03122940b?raw)
