Skip to content
100% local

Split document by headings

Break a document into separate parts, starting a new one at every heading of the level you pick.

Input
Output

Split document by headings

Paste a long document and this tool cuts it into separate parts wherever a heading of the level you choose appears. It is built for the moment a single file has outgrown itself — a specification with dozens of "## " sections that needs to become individual pages, meeting notes structured by numbered agenda items, or a long guide you want to feed into another tool one section at a time.

Four heading formats are supported: Markdown (#, ##, up to ######), underlined titles (a line followed by === or ---), uppercase lines used as headings, and numbered headings such as "1." or "1.1". The level control picks which depth counts as a split point — the number of # for Markdown, the dot-separated digit count for numbered headings, and === versus --- for underlined ones. Choose whether each part keeps its original heading markup or shows a plain, stripped title, and set the text that separates one part from the next.

The remaining options handle real documents, not tidy ones. Turn on part numbering or a per-part word count to annotate the output. Skip parts with no content under their heading, a common leftover from outline drafts. Set a maximum character length and any part that runs longer is broken further at paragraph, then word, boundaries, so nothing is truncated mid-sentence. Switch to a list of titles with their lengths when you need a table of contents rather than the full text.

Splitting runs entirely in your browser — nothing you paste is uploaded anywhere. Copy the result, download it as a .txt file, or send it back into the input to run another tool on it.

FAQ

What counts as a heading for the "uppercase" and "numbered" formats?
An uppercase heading is any non-empty line written entirely in capital letters. A numbered heading is a line starting with digits like "1." or "1.1" — the number of dot-separated digits must match the level you selected, so "2." matches level 1 while "2.1" matches level 2.
What happens to text before the first heading?
It becomes its own part with no heading, unless it is entirely blank — a blank stretch before the first heading is dropped rather than shown as an empty part.
Can I split at every level 2 heading while ignoring level 3 headings underneath it?
Yes — pick level 2 and any level 3 (or deeper) headings inside a section stay as ordinary content inside that part; only the level you choose creates a new split.
What happens if a part is longer than the maximum length I set?
It is broken into further parts at paragraph boundaries where possible, or at word boundaries if a single paragraph is still too long. Each extra part keeps the same heading so you can tell where it came from.
Is my document uploaded anywhere?
No. Splitting runs entirely in your browser — your document never leaves your device.