# Discourse Math plugin

**URL:** https://meta.discourse.org/t/discourse-math/265331
**Category:** Users
**Tags:** chinese-translation
**Created:** [May 17, 2023, 1:34pm UTC](https://meta.discourse.org/t/discourse-math/265331 "2023-05-17T13:34:26Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![honeymoose](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/honeymoose/32/198718_2.png) [@honeymoose](https://meta.discourse.org/u/honeymoose)
#### Post date: [May 17, 2023, 1:34pm UTC](https://meta.discourse.org/t/discourse-math/265331/1 "2023-05-17T13:34:26Z")

</div>

|||  
-|-|-|  
ℹ | **Overview** | **Discourse Math** uses [MathJax](https://www.mathjax.org/) (default) or [KaTeX](https://katex.org/) to let you use math formulas in your Discourse.  
🛠 | **Repo Link** | [https://github.com/discourse/discourse-math](https://github.com/discourse/discourse-math)  
📖 | **Install Guide** | [How to install plugins in Discourse](https://meta.discourse.org/t/install-plugins-in-discourse/19157)

> [@](#):
>
> This plugin is provided by Discourse and is officially supported and maintained.
> 
> If you need any other features, you can directly contact the official Discourse team.

### Enabling Math

The Math plugin can be configured in the settings, accessible via the `admin/plugins` page:

![](https://cdck-file-uploads-global.s3.dualstack.us-west-2.amazonaws.com/meta/original/4X/0/7/8/0783e5858f4219b6624393a8e9ffad5ecdfec133.png)

### Features

Once you have successfully enabled this plugin, you can use `$` symbols to delimit the math expressions you want to render, like in the following example: `$E=mc^2$`.

You can also use `$$` delimiters for block mode math, like this:

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

```

 ![](https://global.discourse-cdn.com/meta/original/4X/a/f/8/af8a522f78267c2d96eb7b3366c65e6a95fb55f5.png)  
Discourse Math uses a heuristic method to ensure that the following content is not converted: “I spent 20$ and another 100$”.

When using MathJax, you can also enable [asciimath](http://asciimath.org/) to render formulas, using `%` as the delimiter: `%E=mc^2%`

### Site Settings

- See all site admin “math” settings

| Name | Description |
| --- | --- |
| Enable Discourse Math | Enable the Discourse Math plugin (will recognize $ and $$ code blocks) |
| Discourse Math Renderer | Default renderer is: [mathjax/katex] |
| Discourse Math Zoom | Zoom in 200% when hovering over math formulas (MathJax only) |
| Enable Accessibility Enhancements | Enable accessibility enhancements (MathJax only) |
| Enable Discourse Math Asciimath | Enable asciimath (will use % as delimiter) (MathJax only) |

> If you are using Discourse’s official hosting service, the Discourse Match plugin is available for all users. Official link: [Math | Discourse - Civilized Discussion](https://www.discourse.org/plugins/math.html)

---

<div class="post-metadata">

### Author: ![honeymoose](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/honeymoose/32/198718_2.png) [@honeymoose](https://meta.discourse.org/u/honeymoose)
#### Post date: [May 17, 2023, 1:35pm UTC](https://meta.discourse.org/t/discourse-math/265331/2 "2023-05-17T13:35:20Z")

</div>

The official discussion about this plugin is at: [Discourse Math](https://meta.discourse.org/t/discourse-math/65770).

You can directly access the official link. Our content is also translated from the official content.

If you have any confusion about the Chinese translation of this plugin or wish to change it, please visit: [Crowdin](https://discourse.crowdin.com/translate/16c5e0dd74114efa353342bcdf62241c/364/en-zhcn/1322?filter=basic&value=0&em)

You can directly change the Chinese translation code.

 ![](https://global.discourse-cdn.com/meta/original/4X/1/1/2/112fc25a9c7888da95a8736b366af4b64ab15a73.png)
