Markdown TOC Generator
Paste Markdown and get a clickable TOC built from your headings (#, ##, ### …) using GitHub-style anchors. Unicode (Korean, Japanese, Chinese) headings are recognized and anchored correctly.
How to Use
Paste the Markdown body into the left pane or type it. The TOC updates as you type.
Pick max depth (H2–H6), whether to skip the first H1 (often the document title), and your bullet marker (-, *, +).
Click Copy to put the TOC on the clipboard. Paste it near the top of your Markdown — GitHub and most blog renderers will turn the anchors into clickable links.
FAQ
How are anchors generated?
GitHub rules: lowercase → spaces become "-" → strip special characters except hyphens and Unicode letters/digits. Korean and Japanese characters are kept; GitHub URL-encodes them in the address bar but clicks still work.
What about duplicate headings?
Same as GitHub: the second occurrence gets "-1", the third "-2", and so on. The first stays unchanged.
Are # symbols inside code blocks treated as headings?
No. Fenced code (```…```) and indented code (4-space) are recognized and excluded so their `#` lines aren't picked up as headings.
Why doesn't my GitHub link work?
GitHub anchors must match the heading text exactly. Inline Markdown (e.g., <code>, [link]()) inside a heading can change the anchor. This tool strips inline Markdown and uses plain text only when generating anchors.
Is anything sent to a server?
No. Parsing and anchor generation run entirely in your browser; your Markdown never leaves the page.