Why Markdown Is the Best Way to Write — and How to Add Math with Mathpix
Markdown lets you focus on content instead of formatting. Pair it with Mathpix to convert handwritten equations into LaTeX instantly.
If you’ve ever fought with Microsoft Word — wrestling with fonts, spacing, bullet alignment, or mysterious formatting that breaks when you copy-paste — Markdown is the cure.
What Is Markdown?
Markdown is a plain-text writing format. You type simple symbols to indicate structure, and a tool converts it to a beautifully formatted document.
Here’s what it looks like:
## This Is a Heading
This is a paragraph with **bold** and *italic* text.
- Bullet point one
- Bullet point two
[Click here](https://example.com) for a link.
That’s it. No menus, no toolbars, no mouse clicks. Just text.
Why Markdown Is Better
1. You own your files
Markdown files are plain .md text files. They open in any editor, on any operating system, forever. No vendor lock-in — unlike .docx, .pages, or Google Docs.
2. Version control friendly
Because Markdown is plain text, Git can track every change you make. You can see exactly what was added, removed, or edited — line by line. Try doing that with a Word document.
3. Focus on content, not formatting
In Word, you spend half your time adjusting margins and fighting with styles. In Markdown, you write. The formatting is handled by your publishing tool (a blog engine, a PDF converter, a slide deck generator).
4. One source, many outputs
The same .md file can become:
- A website (using Astro, Hugo, Next.js)
- A PDF (using Pandoc or Typora)
- A slide deck (using Marp or Reveal.js)
- A book (using mdBook or Jupyter Book)
5. It’s everywhere
GitHub, Notion, Slack, Discord, Reddit, Stack Overflow, Jupyter notebooks — they all use Markdown. Learn it once, use it everywhere.
The Full Markdown Cheat Sheet
| Syntax | Result |
|---|---|
# Heading 1 | Large heading |
## Heading 2 | Medium heading |
**bold** | bold |
*italic* | italic |
~~strikethrough~~ | |
`inline code` | inline code |
[link](url) | Clickable link |
 | Image |
- item | Bullet list |
1. item | Numbered list |
> quote | Blockquote |
--- | Horizontal rule |
``` | Code block (fenced) |
Adding Math Equations
For technical writing — physics, engineering, data science — you need equations. Markdown supports math using LaTeX syntax wrapped in dollar signs:
Inline math: $E = mc^2$ renders as
Block math (centered, on its own line):
$$
\nabla \cdot \mathbf{E} = \frac{\rho}{\epsilon_0}
$$
This renders Maxwell’s first equation — Gauss’s law for electricity.
More examples
The heat equation:
$$
\frac{\partial u}{\partial t} = \alpha \nabla^2 u
$$
A matrix:
$$
\mathbf{A} = \begin{bmatrix} a_{11} & a_{12} \\ a_{21} & a_{22} \end{bmatrix}
$$
An integral:
$$
\int_0^{\infty} e^{-x^2} dx = \frac{\sqrt{\pi}}{2}
$$
The Problem: Typing LaTeX Is Painful
LaTeX syntax is powerful but hard to remember. Writing \frac{\partial^2 u}{\partial x^2} from memory is not fun. And if you have handwritten notes or a textbook equation, retyping it in LaTeX takes forever.
This is where Mathpix comes in.
What Is Mathpix?
Mathpix is a tool that converts images of math into LaTeX code. Take a screenshot of any equation — from a textbook, a whiteboard, your own handwriting — and Mathpix gives you the LaTeX.
How to Use Mathpix
- Download Mathpix Snip from mathpix.com (free tier: 50 snips/month)
- Take a screenshot of an equation (use the Mathpix hotkey —
Ctrl+Alt+Mon Windows,Ctrl+Cmd+Mon Mac) - Mathpix recognizes the math and outputs LaTeX
- Paste the LaTeX into your Markdown file between
$$delimiters
Example Workflow
Say you’re reading a paper and see the acoustic wave equation:
- Screenshot the equation with Mathpix
- Mathpix outputs:
\frac{\partial^2 p}{\partial t^2} = c^2 \nabla^2 p
- Paste it into your Markdown:
The acoustic wave equation:
$$
\frac{\partial^2 p}{\partial t^2} = c^2 \nabla^2 p
$$
where $p$ is pressure and $c$ is the speed of sound.
Done. What would take 5 minutes to type from memory takes 5 seconds.
Mathpix Also Handles
- Tables — screenshot a table, get Markdown or LaTeX table output
- Chemical formulas — H₂SO₄, reaction equations
- Handwritten notes — your own scribbles on paper or iPad
- Full paragraphs — OCR for mixed text and math
Setting Up Math Rendering on Your Website
If you’re running an Astro blog (like this one), you need a plugin to render LaTeX. Add KaTeX or remark-math:
npm install remark-math rehype-katex
Then update your astro.config.mjs:
import remarkMath from 'remark-math';
import rehypeKatex from 'rehype-katex';
export default defineConfig({
markdown: {
remarkPlugins: [remarkMath],
rehypePlugins: [rehypeKatex],
},
});
And add the KaTeX CSS to your layout:
<link
rel="stylesheet"
href="https://cdn.jsdelivr.net/npm/katex@0.16.8/dist/katex.min.css"
/>
Now any $...$ or $$...$$ in your Markdown will render as beautiful equations.
Recommended Markdown Editors
| Editor | Platform | Best For |
|---|---|---|
| VS Code | All | Coding + writing (with Markdown preview extension) |
| Typora | All | WYSIWYG Markdown editing, PDF export |
| Obsidian | All | Note-taking, knowledge base, LaTeX support built-in |
| iA Writer | Mac/iOS | Distraction-free writing |
| Marktext | All | Free, open-source, clean interface |
Summary
- Markdown = write once, publish anywhere, version-control everything
- LaTeX = the standard for math and scientific notation
- Mathpix = screenshot → LaTeX in seconds
- KaTeX/MathJax = render equations on your website
Stop fighting with Word. Write in Markdown.
Tools mentioned: Markdown, LaTeX, Mathpix Snip, KaTeX, VS Code, Astro