Back to list
Text4 min readUpdated 11/2/2026

What Is Markdown? When Do You Need to Remove It?

Learn the basics of Markdown syntax and situations where plain text conversion is necessary.

By webgyver

What Is Markdown?

Markdown is a lightweight markup language created by John Gruber in 2004. It's designed as an easy-to-read, easy-to-write plain text format that can be converted to HTML.

Markdown's philosophy is that 'what you read should convey meaning.' For example, **bold text** is wrapped in asterisks, and # headings start with hash symbols. Document structure can be expressed without complex tags.

Today, Markdown is the standard in GitHub, GitLab, Notion, Obsidian, and most development documentation tools. It's widely used for writing README files, technical documentation, and blog posts.

Basic Markdown Syntax

Headings use # symbols. The number of # indicates heading level. Use # Heading1, ## Heading2, ### Heading3 in order.

Text emphasis uses asterisks or underscores. *italic*, **bold**, ***bold italic***. Strikethrough uses ~~text~~.

Links use [text](URL) format, images use ![alt text](imageURL). Code is wrapped in backticks (`), code blocks use triple backticks (```).

When Markdown Removal Is Needed

When pasting text to platforms that don't support Markdown, syntax symbols appear as-is. In email, word processors, and some social media, Markdown doesn't render, reducing readability.

It's needed when extracting pure text from documents. For example, when using Markdown document content for text-to-speech (TTS) or text analysis, syntax symbols interfere.

When migrating content to different formats, removing Markdown syntax first before converting to the new format can be cleaner. Especially useful when moving only content without formatting from complex Markdown.

Tips for Using the Markdown Stripper

TheWebGyver's Markdown stripper accurately interprets Markdown based on the remark parser. It correctly handles complex nested structures better than simple regex-based tools.

Text within code blocks is also extracted. You can convert entire content at once without separating code and explanations from technical documents.

Preview the conversion results and copy to clipboard with a single click. All processing occurs in the browser, so document content is never sent externally.

Myth vs. Reality: Markdown Is Not a Single Standard

The idea that Markdown syntax is fixed and behaves identically everywhere is only half true. The CommonMark specification states that John Gruber's original description of the syntax does not specify it unambiguously. CommonMark was created to fill that gap, and it defines a heading as one to six # characters, with the heading level equal to the number of # characters.

A second misconception is that tables and strikethrough are part of the basic syntax. In the GitHub Flavored Markdown (GFM) specification, tables are labeled Tables (extension), and strikethrough and task list items are also defined as extensions. A table divided by pipes or ~~strikethrough~~ is something GFM adds on top of CommonMark, so one editor may draw a table while another shows the raw symbols.

A third misconception is that visible symbols mean broken formatting. Gruber's syntax document explains that a Markdown document should be publishable as-is, as plain text. Asterisks and hash marks are not errors but readable markers that belong to the source, and seeing them where nothing renders them is close to the design intent.

Regular Expressions vs. a Parser: A Comparison

The easiest approach is to strip asterisks and hash marks with a regular expression. That is fine for tidying a few asterisks, but the syntax has many exceptions. CommonMark, for example, specifies that an underscore inside a word does not create emphasis, and foo_bar_baz is its example. An underscore in a variable or file name is content rather than formatting, so a regular expression that removes every underscore will break snake_case names.

Code is another problem. The specification notes that backslash escapes do not work inside code spans, so symbols in code are content to preserve rather than formatting. A line that ends with two or more spaces or a backslash becomes a hard line break, and that trailing backslash is a formatting marker that should not survive into the result. A pattern aimed only at asterisks and hash marks misses such symbols.

A parser-based conversion first reads the document as structure, such as headings, paragraphs, lists, code and links, and then pulls the text out of that structure, so these exceptions are left to the grammar rules. That is why TheWebGyver's Markdown stripper uses the remark parser. The trade-off is that a parser interprets the document as valid Markdown, so a symbol that does not follow the rules, such as an unmatched asterisk, is treated as an ordinary character and may remain in the output.

Before You Strip: A Judgment Guide by Element

Tables deserve the most care. A GFM table splits cells with pipes and has a second row of hyphens as a delimiter row, so deleting only the symbols leaves text with no visible columns. Word processors lose table structure in plain text as well: Microsoft explains that Word's Keep Text Only paste converts tables into a series of paragraphs. If the structure matters, move the table into a real table rather than flattening it to text.

A link has the form [text](address), so keeping only the text can drop the address. Tools differ here, so check whether the address survived, and if reference links matter, list them at the end of the text. For lists, decide whether to keep hyphens or numbers. Hyphen lists read well even as plain text, so keeping the marker is often better. Task list checkboxes are a GFM extension, so also look for leftover square brackets after conversion.

For text with a lot of code, it is safer to set code blocks aside and keep them separately. A single character can change what code does, so it is better not to touch it in the name of tidying formatting.

After Conversion: A Five-Minute Review

First, put the original and the result side by side and check that the headings are the same in number and order. When only the heading marker is removed, a heading can look attached to the previous paragraph, so confirm that blank lines between paragraphs remain. Second, check that list items are still distinguishable where you need a list. Third, compare anything that depends on structure, such as link addresses and tables, to make sure nothing disappeared.

Finally, paste the result into the final document and read it through once. Whether the text flows naturally matters more than whether every Markdown symbol is gone. If a few stray asterisks or underscores remain because they did not follow the rules, just delete those by hand.

It is also a good habit to save the original as a separate file before converting, so you can recheck structure-dependent information such as tables and links later. If the same document has to go to several places, keep the Markdown source as it is and make a converted copy only for places that do not understand Markdown. That way, when you edit the document later, you only need to change the one source.

References

Try It Yourself

Experience what you learned in this article with Markdown Stripper.

Markdown Stripper