Home · Docs · Import + Export · Importing — overview

Importing — overview

Drop a file anywhere outside the editor and sweetdocs creates a new document from it. Five formats supported, 25 MB cap per file, format-specific converters under the hood.

The fastest way to bring an existing document into sweetdocs is drag-and-drop anywhere outside the active editor. A new document gets created with the file’s content converted to Markdown.

Drop to create a new document in My Documents
Q4 Roadmap.docx

How importing works

There are three entry points:

MethodResult
Drop a file anywhere outside the editor (sidebar, blank space, top bar)New document is created in the current library
Use the upload menu in the sidebar or appSame — pick from a file picker
Paste a .md file’s contents into a docGoes through Markdown paste handling — see Paste from web

Dropping a file inside an open editor is different — if it’s an image, it embeds inline; if it’s anything else, it falls through to the page-level drop overlay and creates a new doc.

Supported formats

Five formats, detected by file extension:

ExtensionWhere the conversion happensNotes
.md / .markdownClient-sideUsed as-is; see Importing other formats
.txtClient-sidePlain text wrapped as a doc; see Importing other formats
.docxClient-side (mammoth + turndown)See Importing Word
.rtfServer-side (/api/ai/convert-rtf, Gemini)See Importing other formats
.pdfServer-side (/api/ai/convert-pdf, LlamaParse)See Importing PDF

The accept attribute on the file picker is: .md,.markdown,.txt,.docx,.rtf,.pdf.

File size limit

25 MB per file for any import. Anything larger gets rejected with a toast like:

roadmap.pdf is larger than 25 MB.

The same cap applies whether the file is dropped, picked, or sent via the API. Server-side converters enforce the same number.

What happens after a successful import

  1. The new document is created in the current library with the converted Markdown as its body
  2. The document’s title is the filename minus extension (and trimmed)
  3. Title conflicts with existing docs in the same folder are resolved by suffix-renaming
  4. The new document opens in the editor automatically
  5. Any warnings from the converter (e.g., “3 images skipped”, “1 page failed to convert”) show as a toast

Errors

The converter returns one of these error kinds when it can’t proceed:

KindMessage you’ll seeWhat it means
empty”filename is empty.”Zero-byte file
too_large”filename is larger than 25 MB.”Over the size cap
unsupported”filename is not a supported format. Try .md, .txt, .docx, .rtf or .pdf.”Wrong extension
conversion_failedFormat-specific messageServer returned an error; sometimes auth-related
quota_exceededFormat-specific messageLLM-backed converters (RTF, PDF) hit your monthly quota
misconfiguredFormat-specific messageServer-side configuration issue (rare)

Multiple files at once

You can drop multiple files in one go. Each file becomes its own document, processed in series. Errors on one file don’t stop the rest of the batch.

What about importing into an existing doc?

Imports always create a new document. To merge external content into an existing doc, open the doc and paste the source as text (see Paste from web for paste behavior) or open the import as a new doc and copy-paste sections across.