Wiris

Documentation / MathType

  • Demos
  • Visit our website
  • Downloads
  • Contact us
  • MathType

    • WirisQuizzes

      • Nubric

        • CalcMe

          • MathPlayer

            • Store FAQ

              • MathFlow

                • BF FAQ

                  • Miscellaneous

                    • Wiris Integrations

                      • Home
                      • MathType
                      • Technical documentation
                      • MathType for HTML editors
                      • Reference

                      LaTeX support

                      Reading time: 2min

                      This article describes how MathType integrations detect, render, edit, and store LaTeX expressions in supported HTML editors. It is intended for administrators, developers, and content authors who work with LaTeX expressions in MathType.

                      MathType integrations can render existing LaTeX expressions and allow users to edit them visually in MathType. During editing, authors usually see the LaTeX source. When the content is displayed, users see the rendered formula.

                      Requirements/Prerequisites:

                      • A supported MathType integration installed in the target HTML editor.
                      • LaTeX expressions enclosed in double dollar signs: $$...$$.
                      • No other active LaTeX or TeX renderer processing the same expressions.

                      Caution

                      LaTeX is disabled in the MathType integration for Moodle if Moodle's TeX Filter is enabled. This avoids conflicts between both renderers.

                      Concepts:

                      • LaTeX source: The text-based mathematical expression written between $$...$$.
                      • MathML: Mathematical Markup Language; the format MathType uses to store and render formulas.
                      • LaTeX annotation: The original LaTeX expression stored inside the MathML using <annotation encoding="LaTeX">.

                      Reference details

                      Supported behavior:

                      Behavior Supported Description
                      Render LaTeX expressions Yes MathType renders LaTeX expressions enclosed in $$...$$ when the content is displayed.
                      Edit LaTeX visually Yes Users can place the cursor inside a LaTeX expression and open MathType to edit it visually.
                      Edit LaTeX source directly Yes Users can edit the LaTeX code directly in the HTML editor.
                      Store formulas as MathML Yes By default, MathType stores formulas as MathML with the original LaTeX preserved as an annotation.
                      Preserve original LaTeX Yes The original LaTeX is stored in the MathML using the <annotation> element.

                      Delimiter:

                      Delimiter Purpose
                      $$...$$ Marks LaTeX expressions for MathType processing.

                      LaTeX storage model

                      MathType manipulates LaTeX expressions as MathML. When content is submitted, previewed, or published, MathType searches for expressions enclosed in $$...$$ and converts them into MathML.

                      The original LaTeX expression is stored inside the MathML using the <semantics> and <annotation> elements.

                      Example:

                      <math xmlns="http://www.w3.org/1998/Math/MathML">
                        <semantics>
                          <mfrac>
                            <mn>1</mn>
                            <mn>2</mn>
                          </mfrac>
                          <annotation encoding="LaTeX">\frac12</annotation>
                        </semantics>
                      </math>
                      

                      When the HTML editor is opened again, MathType recovers the stored LaTeX from the <annotation> element and displays it in the editor for further editing.

                      diagram.png

                      Supported LaTeX

                      MathType supports LaTeX expressions that can be translated to and from MathML. Support is limited by the compatibility between LaTeX syntax and MathML.

                      Limitations include:

                      • Some LaTeX formulas have no MathML equivalent.
                      • LaTeX is extensible and may include custom commands or non-standard packages that MathType cannot process.
                      • Non-mathematical LaTeX commands, especially formatting commands unrelated to math, may not be supported.
                      • MathType primarily supports LaTeX instructions that have a MathML equivalent.

                      On this page, you can find some examples of supported LaTeX.

                      Configuration

                      API / Method / Configuration:

                      Parameter Type Required Description
                      wiriseditorparselatex Boolean No Controls whether LaTeX expressions are parsed and stored as MathML with a LaTeX annotation.

                      Example usage

                      When wiriseditorparselatex is set to true:

                      LaTeX is parsed and stored as MathML with a LaTeX annotation.

                      <math xmlns="http://www.w3.org/1998/Math/MathML">
                        <semantics>
                          <mn>1</mn>
                          <mo>+</mo>
                          <mn>2</mn>
                          <annotation encoding="LaTeX">1+2</annotation>
                        </semantics>
                      </math>
                      

                      MathType renders this MathML as a formula image.

                      When wiriseditorparselatex is set to false:

                      LaTeX is not parsed or stored as MathML.

                      $$1+2$$
                      

                      MathType does not render this LaTeX code as a formula image. A separate LaTeX renderer must be used.

                      Error handling:
                      If LaTeX expressions are not rendered or converted as expected, check the following:

                      • The expression is enclosed in $$...$$.
                      • The expression uses LaTeX syntax supported by MathType.
                      • No other LaTeX or TeX renderer is processing the same content.
                      • In Moodle, the TeX Filter is disabled if you want MathType to process LaTeX.
                      • The wiriseditorparselatex setting is configured according to the expected storage behavior.

                      Related resources:

                      • LaTeX coverage
                      • MathML coverage by MathType
                      • Configuration table
                      • MathType integrations

                      Was this article helpful?

                      Give feedback about this article

                      Related Articles

                      • MathML makes elementary math accessible
                      • Microsoft Word and Google Docs compatibility
                      • Using MathType with WordPress

                      LaTeX support

                      Caution Reference details LaTeX storage model Supported LaTeX Configuration Example usage

                      Empowering STEM education

                      MathType

                      • Office Tools
                      • LMS
                      • XML
                      • HTML

                      WirisQuizzes

                      Nubric

                      Integrations

                      Solutions

                      • Education
                      • Publishing houses – platforms and interactive
                      • Publishing houses – Print and digital
                      • Technical writers

                      Pricing

                      Downloads

                      Blog

                      • Success stories

                      About us

                      • Careers
                      • Partnership

                      Contact Us

                      Contact Sales

                      European union (European Regional Development Fund) and 1EdTech (TrustEd Apps Certified)
                      • Cookie Policy
                      • Terms of Use
                      • Privacy Policy / GDPR
                      • Student Data Privacy
                      • Compliance
                      • Cookie Settings

                      © Wiris 2026

                      Expand