A premium web application that converts any file to clean Markdown. Powered by Microsoft MarkItDown.
Drop any file into the web UI and get clean, structured Markdown back in seconds. The conversion engine is Microsoft's MarkItDown library — the most popular file-to-Markdown converter on GitHub (119k+ stars).
| Category | Formats |
|---|---|
| Documents | PDF, Word (.docx), PowerPoint (.pptx), Excel (.xlsx/.xls), Outlook (.msg), EPUB |
| Web | HTML, HTM |
| Data | CSV, JSON, XML |
| Images | JPEG, PNG, GIF, BMP, TIFF, WebP (EXIF metadata + OCR) |
| Archives | ZIP (recursive content extraction) |
| Audio | WAV, MP3 (requires speech transcription API key) |
| Text | TXT, Markdown, reStructuredText |
Browser (HTML/CSS/JS)
│
├── Drag-and-drop file upload
│ ↓
├── POST /api/convert (multipart form)
│ ↓
FastAPI Server (server.py)
│
├── Receives file → writes to temp file
├── Passes temp file path to MarkItDown engine
├── MarkItDown detects format by extension
├── Delegates to format-specific converter:
│ ├── PDF → pdfminer.six / pdfplumber
│ ├── DOCX → mammoth
│ ├── PPTX → python-pptx
│ ├── XLSX → openpyxl / pandas
│ ├── HTML → markdownify (html→md)
│ ├── Images → EXIF extraction + optional OCR
│ ├── Audio → SpeechRecognition (optional)
│ └── Text formats → direct read
├── Returns structured Markdown text
├── Cleans up temp file
│ ↓
└── JSON response → browser
│
├── Raw Markdown displayed (left pane)
├── markdown-it renders HTML preview (right pane)
├── Copy to clipboard / Download as .md
└── Saved to localStorage history
-
Upload — User drags a file or clicks to browse. The file is sent as a
multipart/form-dataPOST to/api/convert. -
Temp File — FastAPI receives the upload, writes it to a temporary file with the original extension preserved (MarkItDown needs a file path to detect format).
-
Conversion —
MarkItDown.convert(path)is called. Internally, MarkItDown uses magika for content-type detection and routes to the appropriate format handler. Each handler extracts text and structure, normalizing it to Markdown with headings, tables, lists, and links preserved. -
Response — The server returns a JSON payload with the Markdown text, filename, file size, character count, and conversion time. The temp file is deleted in a
finallyblock. -
Preview — The browser receives the Markdown and renders it two ways simultaneously:
- Raw pane —
textContentassignment (safe, no XSS) - Preview pane — markdown-it parses and renders to HTML
- Raw pane —
-
Export — User can copy to clipboard (Clipboard API with
execCommandfallback) or download as.md(Blob URL). -
History — Each conversion is saved to
localStorage(last 20 entries) with full Markdown content for instant recall.
- No database — All state is client-side (localStorage). Server is stateless.
- Temp file cleanup — Guaranteed via
try/finallyblock. Files are never persisted. - 50MB limit — Enforced both client-side (pre-upload check) and server-side (post-read check).
- Local-only by default — Launchers bind to
127.0.0.1and use a fixed app port. - Hot reload opt-in — Set
APP_RELOAD=1before runningpython server.py.
- Python 3.10+ (tested on 3.12)
- pip
git clone https://github.com/YOUR_USER/MarkItDown.git
cd MarkItDown
pip install -r requirements.txtstart.batOpen http://127.0.0.1:8000 in your browser. Use stop.bat to close the background server.
- Drag any supported file onto the drop zone (or click to browse)
- View results in split pane — raw Markdown (left) and rendered preview (right)
- Copy to clipboard or Download as
.md - History — access past conversions from the sidebar
MarkItDown/
├── server.py # FastAPI backend — file upload, MarkItDown conversion, static serving
├── requirements.txt # Python dependencies
└── static/
├── index.html # Single-page application — drag/drop, results, history sidebar
├── css/
│ └── style.css # Design system — dark mode, glassmorphism, responsive
└── js/
└── app.js # Client logic — upload, preview, clipboard, download, history
Returns the list of supported input formats.
Response:
{
"formats": [
{ "ext": ".pdf", "label": "PDF", "icon": "📄", "category": "Documents" },
...
]
}Converts an uploaded file to Markdown.
Request: multipart/form-data with a file field.
Response:
{
"success": true,
"filename": "report.pdf",
"extension": ".pdf",
"file_size": 245760,
"markdown": "# Report Title\n\nContent here...",
"markdown_length": 4521,
"conversion_time": 1.23
}Error Response (413):
{ "detail": "File too large. Maximum size is 50MB" }| Layer | Technology | Purpose |
|---|---|---|
| Backend | FastAPI | Async web framework |
| Server | Uvicorn | ASGI server |
| Engine | MarkItDown | File → Markdown conversion |
| Frontend | Vanilla HTML/CSS/JS | Zero-dependency UI |
| Preview | markdown-it | Markdown → HTML rendering |
| Fonts | Inter + JetBrains Mono | Typography |
MIT