An easy to use WordPress plugin that provides a simple way for embedding syntax-highlighted source code within pages or posts on your website, without losing it’s formatting or making any manual changes. Supporting 14 languages, 16 shortcodes and 36 themes. The syntax highlighting feature implemented via a CodeMirror library. If you want more options then tell me and I will be happy to add it.


WP Plugin "My Syntax Highlighter" by SpaceX-Chimp

Syntax highlighting is a feature that displays source code, in different colors and fonts according to the category of terms. Syntax highlighting is one strategy to improve the readability and context of the text; especially for code that spans several pages. The reader can easily ignore large sections of comments or code, depending on what they are looking for.

This plugin also uses standalone Shortcode-Processor to prevent WordPress from converting newlines to HTML paragraphs, replacing apostrophes with typographic quotes and so on.

This plugin is just plug and play, no tedious configurations or hacks, just install, enable and start using your new shortcodes.


  • Lightweight and fast
  • Secure code with using clear coding standards
  • Intuitive interface with many settings
  • Cross browser compatible (work smooth in any modern browser)
  • Compatible with all WordPress themes
  • RTL compatible (right to left)
  • Translation ready
  • Published on

Current features:

  • Live preview on Settings Page
  • Standalone Shortcode-Processor
  • Syntax highlighting (by CodeMirror)
  • Line numbering
  • Dollar sign before line
  • 36 Themes
  • 14 Languages
  • 16 Shortcodes
  • Allow shortcodes in the text widget

A list of supported languages:

Click to view language examples. Highlighted with Default theme.

A list of supported shortcodes:

  • [code][/code]
  • [php][/php]
  • [javascript][/javascript]
  • [js][/js]
  • [xml][/xml]
  • [html][/html]
  • [css][/css]
  • [scss][/scss]
  • [less][/less]
  • [sass][/sass]
  • [markdown][/markdown]
  • [perl][/perl]
  • [sql][/sql]
  • [mysql][/mysql]
  • [shell][/shell]
  • [bash][/bash]

A list of supported themes:

  • 3024-day
  • 3024-night
  • ambiance-mobile
  • ambiance
  • base16-dark
  • base16-light
  • blackboard
  • cobalt
  • colorforth
  • eclipse
  • elegant
  • erlang-dark
  • lesser-dark
  • liquibyte
  • mbo
  • mdn-like
  • midnight
  • monokai
  • neat
  • neo
  • night
  • paraiso-dark
  • paraiso-light
  • pastel-on-dark
  • rubyblue
  • solarized
  • the-matrix
  • tomorrow-night-bright
  • tomorrow-night-eighties
  • ttcn
  • twilight
  • vibrant-ink
  • xq-dark
  • xq-light
  • zenburn


  1. Plugin settings page. WP plugin "My Syntax Highlighter" by SpaceX-Chimp
  2. Example of post with added source code and wrapped it in shortcode provided by this plugin. Default theme of highlighter. WP plugin "My Syntax Highlighter" by SpaceX-Chimp
  3. Example of post with added source code and wrapped it in shortcode provided by this plugin. The “The Matrix” theme of highlighter. WP plugin "My Syntax Highlighter" by SpaceX-Chimp
  4. Example of post with added source codes on multiple language and wrapped it in shortcode provided by this plugin. Default theme of highlighter. WP plugin "My Syntax Highlighter" by SpaceX-Chimp

Quick-Start Guide

  1. Upload “My Syntax Highlighter” to the /wp-content/plugins/ directory.
  2. Activate the plugin through the “Plugins” menu in WordPress.
  3. Go to “Settings” → “Syntax Highlighter”.


Just switch to the Text/HTML editor and wrap your source code in one of the supported shortcodes (like [code]...[/code] that is universal shortcode) and this plugin takes care of the rest. Example:



an "example"!

In this case, the shortcode will prevent WordPress from inserting paragraph breaks between This, is and an "example", as well as ensure that the double quotes around example are not converted to typographic (curly) quotes.

To avoid problems, only edit posts that contain your source code in Text/HTML mode.


This plugin is translate ready. But If your language is not available you can make one. The .pot file is included and placed in “languages” folder. Many of plugin users would be delighted if you shared your translation with the community. Just send the translation files (*.po, *.mo) to our email box and we will include the translation within the next plugin update.


gplv3This plugin is open-sourced software licensed under the GNU General Public License, version 3 (GPLv3) and is distributed free of charge.

Commercial licensing (e.g. for projects that can’t use an open-source license) is available upon request.


.ORGDownload from

Fork on Github


Developing plugins is long and tedious work. If you benefit or enjoy this plugin please take the time to:

Arthur Gareginyan
Arthur Gareginyan

Arthur is a designer and full stack software engineer. He is the founder of SpaceX-Chimp and the blog His personal website can be found at

Follow Arthur: