How to open an .md file on a Mac
Checked November 2026 against Apple's guides to choosing an app to open a file, TextEdit and Quick Look, and VS Code's Markdown docs. Coffee isn't affiliated with Apple or Microsoft.
An .md file is a plain text file written in Markdown, so any app that opens text can open it. To glance at one, select it in Finder and press the Space bar. To read and edit it, open it in TextEdit, a code editor or a Markdown editor. To make Finder use the same app every time, choose File, Get Info, then Open with, pick the app and click Change All.
What an .md file is
Markdown is a way of marking up text with ordinary characters. A line starting with # is a heading, words between ** are bold, and a line starting with - is a list item. The file itself holds nothing else: no fonts, no hidden formatting, just the characters you see. README files, notes from apps such as Obsidian, and documents written by AI tools are often .md files.
That's why the question is less "can my Mac open it" and more "how do I want to see it". Some apps show the raw text with its symbols. Others draw it as a formatted page, with real headings and bold. If you're new to the symbols, this cheat sheet lists them.
Quick Look, to peek
Select the file in Finder and press the Space bar. Quick Look opens a preview without starting any app, and pressing the Space bar again closes it.
What you see depends on your Mac. Apple's guide doesn't mention Markdown, and an app you've installed can add a Quick Look extension that formats it. If you see headings and bold, something is formatting it. If you see the symbols, or only an icon, nothing is. There's more on this in finding notes with Spotlight and Quick Look.
TextEdit, which shows the raw text
TextEdit comes with every Mac, so it's the quickest way to open the file for editing. Control-click the file, choose Open With, then TextEdit.
You'll see the Markdown as it is, with every # and * in place. That's fine for a small change. TextEdit doesn't draw Markdown as a formatted page, and Apple's guide doesn't mention Markdown at all. One thing to watch: TextEdit starts new documents in rich text, so if you copy text from an .md file into a new TextEdit document and save it, you get an .rtf file, not Markdown. Choose Format, then Make Plain Text first. For more on where TextEdit fits, see TextEdit alternatives for writing on the Mac.
A code editor
If you already use one, it's a good choice. VS Code is free and opens Markdown with coloured syntax, and ⇧⌘V shows a formatted preview, or ⌘K then V shows it side by side. Xcode, if you have it, opens .md files as text too. A code editor is at its best when the Markdown sits beside code, such as a project's README.
A Markdown editor
If you'll be reading or writing Markdown often, a Markdown editor shows the file as a formatted page while keeping it plain text underneath. There are free and paid ones. This comparison covers the main Mac options, and this one the free ones.
Coffee is one of them. It opens .md, .markdown and .txt files, shows headings, lists, tables and images formatted as you type, and saves back to the same plain file. It's a Mac app for macOS 15 or later, free for 14 days and then paid.
Opening it once with a different app
Apple's guide gives several ways to open a file with an app that isn't the default:
- Drag the file onto the app's icon in the Dock or in Finder.
- Control-click the file, choose Open With, and pick the app.
- Open the app first, then use File, then Open.
None of these change what happens next time you double-click.
Changing the default app for .md files
To make every .md file open in the same app:
- Select an
.mdfile in Finder. - Choose File, then Get Info, or Control-click and choose Get Info.
- Click the arrow next to Open with.
- Choose the app from the pop-up menu.
- Click Change All, then confirm.
Apple warns that Change All affects every file of that type, so skip it if you only want this one file to open differently. Files ending .markdown are a separate type, so repeat the steps on one of those if you have them.
In Coffee
Coffee's Settings has a button that makes it the default app for Markdown files, so double-clicking an .md, .markdown or .txt file in Finder opens it in Coffee. It does the same job as Change All, in one click. It also adds a Quick Look extension, so the Space bar in Finder can show a note formatted, with headings, lists and tables. If another app's Quick Look extension also claims Markdown, macOS may use that one instead.
If you change your mind, use the Get Info steps above to pick another app.
Questions
Can I open an .md file without installing anything?
Yes. TextEdit opens it as plain text, with the Markdown symbols showing, and Quick Look can preview it from Finder.
Why does my .md file show # signs and asterisks?
Because the app you opened it in shows the raw text. Markdown uses those characters for headings and bold, and an app that draws Markdown shows them as formatting instead.
How do I make a Markdown file always open in the same app?
Select it in Finder, choose File, then Get Info, pick the app under Open with, and click Change All. Coffee also has a button in Settings that does this for Markdown files.
Is an .md file safe to open?
It's plain text, so it can't run anything when you open it in a text editor. Links inside it still go wherever they point, so treat them as you would links in an email.