MathType for WordPress

NOTE: This page is for using MathType Web in WordPress. It's also possible to use MathType Desktop in WordPress. If you're looking for instructions on using MathType Desktop in WordPress, please see our other page of instructions for that.

MathType for WordPress integration consists of these two packages.

MathType integration for WordPress MathType integration for TinyMCE for PHP

  • WordPress 3.0 or higher installed. See special instructions below for WordPress greater than 5.0.
  • TinyMCE as text editor (also known as Classic). WordPress versions earlier than 5.0 use it as default. WordPress 5.0 and later use Gutenberg, a block editor. See instructions below.
  • A valid license to install the integration in a production environment; otherwise, you can use the downloaded file just for demo purposes.
  1. Unzip MathType integration for WordPress and add tiny_mce_wiris.php inside /wp-content/plugins
  2. Unzip MathType integration for TinyMCE and PHP package and add tiny_mce_wiris directory inside /wp-includes/js/tinymce/plugins
  3. Activate WordPress MathType integration in your WordPress plugins administration.
  4. Give write permissions to /wp-includes/js/tinymce/plugins/tiny_mce_wiris/cache and /wp-includes/js/tinymce/plugins/tiny_mce_wiris/formulas directories to the web server user (it will be used to store formula MathML codes and temporal images).

Include WIRISplugins.js script in the header.php file of your theme right before the </head> closing tag. Using WordPress the tag would be like this:

<script src="<?php echo get_option('home');?>/wp-includes/js/tinymce/plugins/tiny_mce_wiris/integration/WIRISplugins.js?viewer=image" type="text/javascript"></script>
Note: Some WordPress versions may add line breaks around formula images, this is related to WordPress default wpautop filter. You can disable wpautop behavior using an integration like this or you can enable the image mode in our plugin.

Optionally, edit /wp-includes/js/tinymce/plugins/tiny_mce_wiris/configuration.ini to set your own values This table specifies all possible parameters.
Also take a look at the documentation of MathType integration for TinyMCE.

In order to check if the integration is installed correctly, there is a page that makes some tests on your server. Open this link to see where is your test page.

Visit this page if you want to know how to clean the cache folder and backup your formula images.

NOTE: This page is for using MathType Web in WordPress. It's also possible to use MathType Desktop in WordPress. If you're looking for instructions on using MathType Desktop in WordPress, please see our other page of instructions for that.

The process described below covers both WordPress pages and WordPress posts, but we will not mention both. The process is the same. We further assume you are using WordPress 5.0 or later, but other than the mention of the block editor, the process is the same for earlier WordPress versions.

Write an equation

This process will not work with the standard WordPress installation. You must have either the TinyMCE Advanced plugin or the Classic Editor plugin installed (or both).

If you have the Classic Editor plugin installed, and are using Classic mode to write/edit the page, skip step 1 and proceed with step 2. These steps will assume you're working with the TinyMCE Advanced editor.

  1. You cannot add an equation to a Paragraph block. To add an equation to a post, add a Classic Paragraph block by clicking the keyboard icon on the page:
    Adding a Classic Paragraph block to WordPress
  2. Click the MathType button on the Classic toolbar to open the MathType editor:
    Click the MathType button to open the MathType editor.
  3. Create the equation and click OK to insert it into the paragraph:
    ""

Edit an equation

  1. Select the formula you want to edit, then open MathType by clicking the MathType button on the toolbar.
  2. Make the changes to the formula, then click OK to save the changes to the post.
    Select the equation then click the MathType button to open the MathType editor to edit the equation.