MagmaNex LogoMagmaNex

Markdown TOC Generator

Generate a nested, linked table of contents from your Markdown headings automatically.

What does this tool do?

The Markdown TOC Generator automatically creates a nested, linked table of contents from your Markdown headings. It scans your heading levels to produce an indented list and links each entry to its section. The whole process runs entirely in your browser.

How to use it

  1. Paste your text into the input area.
  2. Adjust the options to fit your needs.
  3. Copy the processed text.

How it works

The tool scans the # markers in your text and builds a nested list, indenting lower levels like ## and ###. For each heading it generates a GitHub-style slug: the title is lowercased, spaces become dashes, and special characters are removed to form a clickable link in the [Title](#title) format.

Common use cases

It is ideal for adding a navigation-friendly table of contents to long README files, technical guides, and documentation pages. Since listing headings by hand becomes tedious as a document grows, it is used to quickly regenerate the TOC whenever the section structure changes.

Frequently asked questions

What system are the link anchors generated by?

Slugs are generated following common GitHub rules: the heading is lowercased, spaces become dashes, and punctuation is removed, so the links work correctly on GitHub.

Can I choose which heading levels to include?

Yes, you can usually limit it to include only certain levels (such as ## and ###) so that very deep headings do not clutter the table of contents.

Is Markdown TOC Generator free?

Yes. Markdown TOC Generator and all 300+ tools on MagmaNex are completely free with no signup or account required.

Is my data safe?

Yes. Everything runs locally in your browser. The data you enter is never sent to a server, stored, or shared.

Does it work on mobile?

Yes. Markdown TOC Generator works on phones, tablets and desktops — no app download needed.

🔒 Privacy: everything runs in your browser, your data is never sent to a server.

Related Tools

📝 Related Articles

Popular Tools