# Files & Editors

Monofile stores your files in the cloud and opens each one in the right editor automatically — markdown, code, diagrams, HTML, images, and video all live in one workspace.

## What you can store

Monofile recognizes dozens of file types by extension and picks an editor for each:

| File type | Extensions | Opens in |
|---|---|---|
| Markdown | `.md`, `.mdx`, `.txt`, no extension | WYSIWYG editor |
| Code | `.ts`, `.py`, `.go`, `.rs`, `.json`, `.yaml`, and many more | Code editor |
| Diagrams | `.draw` | Whiteboard canvas |
| HTML | `.html`, `.htm` | Live preview |
| Images | `.png`, `.jpg`, `.gif`, `.svg`, `.webp`, and more | Image viewer |
| Video | `.mp4`, `.webm`, `.mov`, and more | Video player |

Files with an unrecognized extension open as plain text in the code editor.

## The editors

- **Markdown** opens in a WYSIWYG editor: you see formatted text, not raw syntax, and everything saves as plain markdown. See [[Writing Markdown]] for the full experience.
- **Code** opens in a Monaco-based editor (the engine behind VS Code) with syntax highlighting for the file's language.
- **Diagrams** (`.draw` files) open in an Excalidraw whiteboard for freehand sketches and diagrams.
- **HTML** renders in a sandboxed live preview.
- **Images and video** open in a built-in viewer or player.

Markdown and HTML files have a **raw toggle** that switches between the rendered view and the underlying source in the code editor.

## Folders, panes, and tabs

Files live in a folder tree in the sidebar. Opening a file adds a tab; you can keep many tabs open and drag them to reorder.

Split the workspace into multiple panes to view files side by side, and drag the divider to resize them. You can drag tabs between panes, or open the same file in two panes — edits in one pane appear live in the other.

Quick navigation: press `⌘P` to fuzzy-search and open any file by name. See [[Writing Markdown]] for the full command palette.

## Uploads

Drag images or video into your workspace to upload them. Uploads go straight to cloud storage; videos get an automatic thumbnail. Uploads must be image or video files and can be up to 500 MB each.

Text-based files (markdown, code, HTML, diagrams) are created directly in the app — use the new-file button in the sidebar or the command palette.

## Saving

There is no save button. Every editor autosaves: shortly after you stop typing, changes are written to the cloud. If you're signed out, files are kept locally in your browser instead, and very large text files (over 5 MB) show a warning before opening.

Your files are also reachable by AI agents through the Monofile API — the same content you edit in the browser, no export step. See [[Agent Quickstart]] if you want an agent working alongside you.
