# Control Markdown ordered lists without relying on typed numbers

Canonical: https://githtml.com/guides/markdown-ordered-list-renumbering
Published: 2026-11-23
Publisher: WaveTech LLC / gitHtml

Treat rendered list numbering as a presentation feature, not a stable identifier for procedural steps. Markdown processors commonly derive a sequence from the list structure rather than preserving every typed number. Use named checkpoints when other documents must reference a step, and preview interruptions such as notes or examples before publishing.

## Identify whether the number carries meaning

A sequence of installation actions benefits from automatic numbering because inserted steps can shift naturally. A protocol field number, legal clause identifier, or externally referenced checklist item is different: its number is data. Do not represent those identifiers using a mechanism that may renumber them. Name meaningful checkpoints, such as Verify the sample connection, and reference that name from troubleshooting material. This makes the procedure more resilient when you add a prerequisite. Before editing a long list, identify which numbers are merely visual order and which have been copied into support responses or another guide.

## Test continuation and interruption explicitly

Create a fixture with three steps, then add a paragraph and a code example within the second step. Preview whether the third step continues the sequence or begins another list. Indentation and blank lines determine structure, so changing only the visible digit may not fix an accidental interruption. The example deliberately repeats source numbering to demonstrate that source digits and rendered sequence are separate concepts. Follow the project's formatter convention rather than fighting it. If the procedure branches, use clearly named alternatives instead of trying to encode complex flow through skipped or repeated numbers. Each branch should explain when the reader chooses it.

````markdown
1. Prepare a disposable sample.
1. Run the documented read-only check.
1. Compare the result with the expected observation.
````

## Review references after reorganizing the procedure

Read the final rendered sequence from the beginning and confirm that no action has been accidentally merged into the previous item. Search for phrases such as step three and update references affected by the edit. Prefer task names in future cross-references, particularly when the page is frequently revised. Have a reviewer execute only the safe sample procedure in a suitable environment; a syntactically correct numbered list can still omit a prerequisite. Keep optional explanation visually subordinate to the required action. If you export the document, check numbering again because a second processor may interpret a boundary differently from the repository preview.

1. Classify each number as ordering or a stable identifier before editing the list.
2. Preview a realistic interruption containing a paragraph and code, not only consecutive short lines.
3. Search for external and internal step-number references after inserting or removing actions.
4. Use named checkpoints for instructions that support teams will reference repeatedly.

## Sources and further reading

- [CommonMark specification](https://spec.commonmark.org/0.31.2/)

## Related guides

- [Why Markdown inside an HTML block stops formatting](https://githtml.com/guides/markdown-raw-html-block-boundaries)
- [Maintain repeated Markdown images with reference labels](https://githtml.com/guides/markdown-reference-style-images)
- [Use reference-style Markdown links without broken labels](https://githtml.com/guides/markdown-reference-style-links)
- [Why a line of dashes turns Markdown text into a heading](https://githtml.com/guides/markdown-setext-heading-confusion)

Editorial approach: https://githtml.com/guides/about
