Enable mathematical typesetting via Extras->Mathematical Typesetting. The following syntax is supported:

• AsciiMath between , eg. a^2+b^2 = c^2`
• LaTeX between $$, eg.$$\sqrt{3×-1}+(1+x)^2
• Inline LaTeX between $$and$$, eg. $$\sqrt{3×-1}+(1+x)^2$$

Here is an example.

If the math is not converted, try clicking the </> button in the toolbar to show hidden HTML tags. This feature is not available in Confluence Server, draw.io offline and draw.io for Chrome OS. It should only be used if the diagram contains mathematical typesetting as it affects rendering performance. SVG export is currently not supported. MathJax is used for rendering.