Developer Tools
Markdown Reference Link Converter
Convert Markdown links between inline [text](url) and reference [text][id] style with definitions at the bottom. Works for images too. In your browser.
Direction
Convert in either direction. Fenced code blocks, inline code, and HTML comments are preserved.Options
Converted Markdown
0 charsInline links converted
0
Reference ids created
0
Inline images converted
0
How to use
- Pick the direction: Inline to reference converts [text](url) to [text][id] with a definitions block; Reference to inline does the reverse.
- Choose the reference id style for inline-to-reference: Numeric ids ([1], [2], ...) match the GitHub release-notes convention; Text ids slugify the link text so the definitions block reads like a glossary.
- Toggle Dedupe by URL to reuse a single id when the same URL appears in several places. Toggle Include images to also rewrite .
- Paste your Markdown into the input on the left. The converted Markdown appears on the right and updates as you type.
- Open the Diagnostics panel for orphaned references, unused definitions, and empty-URL warnings, and the definitions table to copy individual reference lines or the whole block.
- Use Swap direction to feed the result back as input, useful for sanity-checking a round trip, or Load sample to see a worked example before pasting your own document.
About this tool
Markdown Reference Link Converter switches Markdown documents between the two link styles the spec defines: inline links written as [text](url "title") and reference links written as [text][id] with a [id]: url "title" definition somewhere in the file. The inline-to-reference direction is the one most writers reach for when a long-form post, a release note, a wiki page, or a README has accumulated so many embedded URLs that the prose has become hard to skim. The converter walks the document once, skips fenced code blocks (``` and ~~~), inline code spans, and HTML comment blocks so links inside those regions stay byte-for-byte identical, then collects every inline link and every inline image and rewrites them into [text][id] (or ![alt][id]) with a definitions block placed at the bottom of the document or right after the first paragraph. Reference ids can be numeric ([1], [2], [3] in source order) or text-based (slugified from the link text, with -2, -3, suffixes for collisions). When the same URL appears in several inline links the dedupe-by-URL option reuses a single id so the definitions block stays compact and a future URL change can be made in one place. The reference-to-inline direction reads every [text][id], [text][] collapsed reference, and shortcut reference [text] whose label matches a defined id, looks up the matching [id]: url "title" definition (case-insensitive, the way CommonMark requires), inlines the destination back into the body, and strips the no-longer-needed definitions block. Titles are preserved in both directions and re-quoted with the safer quote character when the title itself contains a quote. The diagnostics panel reports orphaned references whose ids do not match any definition, definitions that are not used anywhere in the body, and inline links with an empty URL so a final pass can tidy the document. The link table lists every reference id, URL, and title so a reviewer can copy a single definition line or the whole block. Everything is local: the parser is a small browser-only tokenizer, no markdown library is loaded, and the Markdown you paste here is never uploaded.
Free to use. Works in your browser. No signup, no login.
Related tools
You may also like
Markdown Anchor Link Generator
Heading anchor IDs for GitHub, GitLab, Bitbucket, Hugo, and Pandoc with bulk TOC builder.
Open tool
TextMarkdown Link Extractor
Pull every inline, reference, autolink, and image link out of Markdown.
Open tool
DeveloperMarkdown Cheat Sheet
Searchable Markdown syntax reference with rendered previews and flavor filters.
Open tool
ConverterMarkdown to HTML Converter
Convert Markdown to clean HTML with a live preview and copy button.
Open tool
TextMarkdown TOC Generator
Build a GitHub-style Markdown table of contents from any document.
Open tool
TextMarkdown Editor
Live markdown editor with toolbar, preview, table of contents, and .md or .html download.
Open tool
ConverterHTML to Markdown Converter
Convert HTML to GFM Markdown with tables, code, and reference links.
Open tool
DeveloperMarkdown Table Formatter
Realigns GFM pipe tables in source view with per-column alignment.
Open tool