Math doesn't render in .md Preview

Where does the bug appear (feature/product)?

Cursor IDE

Describe the Bug

even the simplest math doesn’t render when you hit the “preview” button when viewing markdown. I know you know this and it’s frustrating.

Steps to Reproduce

I’m sure you know.

Operating System

Windows 10/11

Version Information

Version: 3.4.20 (user setup)
VSCode Version: 1.105.1
Commit: 0cf8b06883f54e26bb4f0fb8647c9500ccb43310
Date: 2026-05-15T02:26:10.351Z
Layout: editor
Build Type: Stable
Release Track: Default
Electron: 39.8.1
Chromium: 142.0.7444.265
Node.js: 22.22.1
V8: 14.2.231.22-electron.0
OS: Windows_NT x64 10.0.26200

Does this stop you from using Cursor

No - Cursor works, but with this issue

Hey, thanks for the report. By default, Cursor’s .md Preview renders math via the built-in Markdown Math extension KaTeX, so it should work out of the box. To figure out what’s breaking on your side, I’ll need a bit more info:

  1. Send a specific Markdown snippet that doesn’t render, even just a couple lines like $x^2$, $$\frac{a}{b}$$, etc.
  2. Share a screenshot of the Preview window showing that content.
  3. Please check two things:
    • Press Ctrl+Shift+X, search for @builtin markdown-math, and make sure the Markdown Math extension is enabled, not disabled.
    • Press Ctrl+,, search for markdown.math.enabled, and confirm whether it’s enabled or disabled.

Also make sure you’re using the built-in preview via Ctrl+Shift+V, not a third-party Markdown preview plugin. Those often don’t support KaTeX without extra setup.

Once you share the example, I’ll check if we can reproduce it on our side.

I am having the same issue in both Mac and Windows environments. The Katex math extension and the key-value are both enabled. Note: I am seeing this issue in the native cursor Preview editor pane,

image

and not in the Markdown extension preview.

For $(n)$ examples, predictions $(\hat{y}_i)$, targets $(y_i)$:

$$
J(w) = \frac{1}{n} \sum_{i=1}^{n} (y_i - \hat{y}_i)^2
$$

I have the same issue when rendering the preview. I confirm that “markdown.math.enabled”: true in my settings and the extension is enabled.

My code is the following

# Some header

Some text followed by some math 

$$
E = mc^2
$$

and the preview is

Working on a mac. Here are the specs:

Version: 3.8.11 (Universal)
VS Code Extension API: 1.105.1
Commit: e56ad3440df06d22ca7501e65fd518e905486ef0
Date: 2026-06-18T01:40:18.333Z
Layout: editor
Build Type: Stable
Release Track: Default
Electron: 40.10.3
Chromium: 144.0.7559.236
Node.js: 24.15.0
V8: 14.4.258.32-electron.0
xterm.js: 6.1.0-beta.256
OS: Darwin arm64 24.4.0

Hey, thanks for the clear repro, that really helps.

Key point: based on the reports in this thread, math breaks only in Cursor’s native Preview panel, but it renders fine in the built-in VS Code preview. Try opening the preview like this:

  • Cmd+Shift+V or Ctrl+Shift+V, or Command Palette Cmd+Shift+P or Ctrl+Shift+P then Markdown: Open Preview to the Side.

That preview uses the built-in Markdown Math KaTeX and should correctly render $...$ and $$...$$. Let me know if your example $$ E = mc^2 $$ renders there, then we’ll know the issue is limited to the custom Preview panel.

This native preview bug is known and reproduces for several users on macOS and Windows. I reported it internally, but I can’t share an ETA for a fix yet. The workaround above should unblock you for now.