Discourse Math

:discourse2: Summary Discourse Math uses MathJax (default) or KaTeX to render maths in your Discourse forum.
:open_book: Install Guide This plugin is bundled with Discourse core. There is no need to install the plugin separately.

Enabling Math

The Math plugin can be enabled from its settings, accessed from your admin/plugins page:

Math settings

Features

Once enabled, you can render inline math by wrapping with a single $ like so: $E=mc^2$.

You can render blocks of maths by wrapping with $$

$$
\sqrt{(-1)} \; 2^3 \; \sum \; \pi
$$

Discourse Math uses a heuristic to ensure that sentences such as: β€œI spent 20$ and another 100$” do not get converted.

When using MathJax, you can also enable asciimath processing which uses % as a delimiter: %E=mc^2%

Site Settings

  • See all relevant site settings by searching your admin settings for β€œmath”
Name Description
discourse math enabled Enable Discourse Math plugin (will add special processing to $ and $$ blocks)
discourse math provider Default math rendering provider [mathjax/katex]
discourse math zoom on hover Zoom 200% on hover (MathJax only)
discourse math enable accessibility Enable accessibility features (MathJax only)
discourse math enable asciimath Enable asciimath (will add special processing to % delimited input) (MathJax only)

:discourse2: Hosted by us? This plugin is available on all of our hosting tiers Math | Discourse - Civilized Discussion

Last edited by @tobiaseigen 2025-07-16T21:22:59Z

Check documentPerform check on document:
67 Likes