Guide • Free .md viewer below

What Is an MD File?

An .md file is a plain text file written in Markdown, a simple way to mark up text where # starts a heading and ** around a word makes it bold. Any text editor can open it. To read it formatted, drop it in the viewer below.

Markdown
Preview

Open a .md file or paste Markdown to see it rendered.

Export

Runs in your browser · Nothing is uploaded

The viewer above is a working Markdown viewer. Drop your .md file anywhere on the page, click Open file, or paste the text into the left panel, and the formatted document shows on the right. It runs in your browser, and the file is never uploaded. The rest of this guide explains what an MD file is and how to open one on every common device.

What Markdown is

Markdown is a way of writing formatted text using ordinary characters. John Gruber created it in 2004, with help from Aaron Swartz, so people could write for the web without typing HTML tags. The idea is that the raw file should still be easy to read, even before anything formats it.

A file saved with the .md extension holds Markdown text. There is nothing binary or hidden inside it. Open it in any text editor and you see exactly what was typed.

A tiny example

Here is what the inside of an .md file looks like:

# Trip checklist

Pack the **passports** first.

- Chargers
- Rain jacket
- [Hotel booking](https://example.com)

A Markdown viewer turns that into a formatted page: "Trip checklist" as a large heading, "passports" in bold, a bulleted list of three items, and "Hotel booking" as a clickable link. The symbols do the work: # for headings, ** for bold, - for list items, and [text](url) for links. The Markdown cheat sheet lists every element.

Where .md files come from

You are most likely to run into an .md file in one of these places:

  • GitHub and other code hosts. Almost every software project has a README.md at the top of its folder. GitHub shows it formatted on the project's main page, but if you download the project, you get the raw file.
  • Documentation. Many software manuals, wikis and help sites are written as folders of .md files and published by a static site generator such as Jekyll, Hugo, Docusaurus or MkDocs.
  • Notes apps. Obsidian stores every note as an .md file in a normal folder on your computer. Other note apps can export notes as Markdown.
  • AI chat tools. ChatGPT, Claude and Gemini write their answers in Markdown, and exports or downloaded answers often arrive as .md files.
  • Converted documents. People convert PDFs and Word files to Markdown to feed them to AI tools or to keep notes in plain text. You can do that with the Markdown converter.

.md vs .markdown vs .mdx vs .txt

Extension What it is
.md Markdown. The most common extension by far.
.markdown Also Markdown, with the same content. Just a longer name.
.mdx Markdown that can also contain JSX components, used by React-based sites. It needs a build tool to render fully.
.txt Plain text with no implied format. A .txt file can contain Markdown, but apps won't assume it does.

Renaming a .markdown file to .md, or the reverse, changes nothing about the content. Our viewer opens .md, .markdown and .txt files.

How to open an .md file

Because an .md file is plain text, opening it is never the problem. The question is whether you want to see the raw symbols or the formatted result.

On Windows

  1. Notepad. Right-click the file, choose Open with, then Notepad. Notepad on Windows 11 has been gaining Markdown support since 2025: current versions show headings, bold, lists and links formatted, with a toggle in the status bar at the bottom (or in the View menu) to switch between the formatted view and the raw syntax. Formatting can be turned off in Notepad's settings. Older versions, including Notepad on Windows 10, show only the raw text.
  2. VS Code. Open the file in Visual Studio Code, which is free, and press Ctrl+Shift+V to open a formatted preview. Press Ctrl+K, then V, to show the preview side by side with the text while you edit.
  3. Your browser. Drop the file onto the Markdown viewer (or the one at the top of this page). Nothing to install.

On Mac

  1. TextEdit. Right-click the file, choose Open With, then TextEdit. You will see the raw Markdown as plain text.
  2. Quick Look. Select the file in Finder and press the Space bar. macOS has no built-in Markdown renderer for Quick Look, so the preview shows raw text. Third-party Quick Look extensions such as the free, open-source QLMarkdown add formatted previews.
  3. VS Code. Open the file and press Cmd+Shift+V for the formatted preview.
  4. Your browser. Drop the file onto the viewer on this page.

On Linux

  1. Any text editor. gedit, Kate, nano or vim all open .md files as text. In a terminal, cat README.md prints it.
  2. glow. For a formatted view in the terminal, install glow from your package manager and run glow README.md. It renders headings, lists, tables and code with colors.
  3. VS Code or your browser, the same way as on Windows.

On iPhone, iPad and Android

Phones have no built-in Markdown viewer. On iPhone and iPad, the Files app shows an .md file as plain text, with the symbols visible. Most Android file managers do the same or ask which app to use. You have three options:

  • Use the viewer on this page. Open this page in Safari or Chrome, tap Open file, and pick the .md file from your phone's files. It works the same as on a computer.
  • Import it into Apple Notes. Since iOS 26, Apple Notes can import Markdown files and keep headings, links and lists.
  • Install a Markdown app. Obsidian runs on both iOS and Android, and the app stores have many smaller Markdown readers.

How to edit an .md file

Any text editor can edit an .md file. Change the text, keep the symbols, and save. For a nicer experience, use an editor with a live preview: VS Code with the side-by-side preview, Obsidian, or Typora. Save with the .md extension and UTF-8 encoding, which is the default in almost every modern editor.

If you only need to copy text out of the file, open it in the viewer above and click Copy as text. You get the words without the Markdown symbols.

How to convert an .md file to PDF, HTML or Word

  • To PDF. Open the file in the Markdown to PDF converter and click Download PDF. The PDF keeps real, selectable text and clickable links, and it is built in your browser.
  • To HTML. Open the file in Markdown to HTML and copy or download clean HTML, either as a fragment or as a full web page.
  • To plain text. Markdown to plain text strips the symbols and keeps readable text.
  • To Word. Open the file in Markdown to Word and download a real .docx with headings, lists and tables. To paste the formatted text straight into a Google Doc instead, use Markdown to Google Docs.

How to create an .md file

Open any text editor, write your text using Markdown symbols, and save the file with a name ending in .md, such as notes.md. In Notepad, set Save as type to All files so Windows doesn't add .txt to the end.

If you already have the content in another format, convert it instead of retyping it. The Markdown converter turns PDF, Word, HTML, CSV, Excel and other files into a clean .md file in your browser. For a Word document, use Word to Markdown, and for a PDF, use PDF to Markdown.

Is an .md file safe to open?

An .md file is plain text and cannot run anything by itself. Opening one in a text editor is as safe as opening a .txt file.

Two things are worth knowing. First, Markdown files can contain links, and a link can point anywhere, so treat links in a file from a stranger the way you would treat links in an email. Second, Markdown allows raw HTML inside the text. A careless viewer could display that HTML as-is. The viewer on this page cleans the output before showing it: scripts, event handlers, javascript: links, forms and style tags are removed, so a hostile file cannot run code in the page.

The usual warning still applies: a file named something.md.exe is a program, not a Markdown file. Check the full file name if your computer hides extensions.

FAQ

MD File FAQ

Need an .md file from a PDF or Word document?

Convert PDF, Word, HTML, CSV and Excel files to Markdown in your browser.

Open the Converter