···11+---
22+name: markitdown
33+description: Convert websites and URLs to LLM ready Markdown. Use to save tokens when reading websites (headings, lists, tables, links), YouTube URLs (transcripts) and PDFs (including stdin with -x or -m hints). If `markitdown` fails, fall back to `curl r.jina.ai/URL`.
44+---
55+66+# MarkItDown
77+88+Installed extras in this environment: `markitdown[pdf,youtube-transcription]`.
99+1010+1. Convert websites and URLs.
1111+1212+Web page to Markdown:
1313+1414+```bash
1515+markitdown 'https://example.com' -o page.md
1616+```
1717+1818+If MarkItDown fails on a URL, fall back to r.jina.ai:
1919+2020+```bash
2121+curl -fsSL 'https://r.jina.ai/https://example.com' > page.md
2222+```
2323+2424+YouTube URL to transcript Markdown:
2525+2626+```bash
2727+markitdown 'https://www.youtube.com/watch?v=VIDEO_ID' -o video.md
2828+```
2929+3030+2. Convert PDFs.
3131+3232+Convert a file (stdout):
3333+3434+```bash
3535+markitdown path/to/file.pdf
3636+```
3737+3838+Write to a file:
3939+4040+```bash
4141+markitdown path/to/file.pdf -o output.md
4242+```
4343+4444+If reading from stdin, set hints so MarkItDown picks the PDF converter:
4545+4646+```bash
4747+cat file | markitdown -x pdf
4848+cat file | markitdown -m application/pdf
4949+```