Plugin Directory

Enlighter - Customizable Syntax Highlighter

Simple post syntax-highlighted code using the EnlighterJS MooTools Plugin.

Enlighter is a free, easy-to-use, syntax highlighting tool for WordPress. It's build in PHP and uses the MooTools(Javascript) based EnlighterJS to provide a beautiful code-appearance. Using it can be as simple as selecting an editor style or adding shortcode around your scripts which you want to highlight and Enlighter takes care of the rest. An easy to use Theme-Customizer is included to modify the build-in themes without any css knowlegde! It also supports the automatic creation of tab-panes to display code-groups together (useful for multi-language examples - e.g. html+css+js) A theme demo can be found here

Plugin Features

  • Support for all common used languages
  • Theme Customizer including LIVE Preview Mode
  • Inline Syntax Highlighting
  • Full Visual-Editor (TinyMCE) Integration (Admin Panel + Frontend)
  • Easy to use Text-Editor mode through the use of Shortcodes
  • Advanced configuration options (CDN usage, ..) are available within the options page.
  • Supports code-groups (displays multiple code-blocks within a tab-pane)
  • Outputs in various formats like ordered lists or inline. Choose the method that works best for you.
  • Extensible language and theme engines - add your own one.
  • Simple CSS based themes
  • Integrated CSS file caching (suitable for high traffic sites)
  • EnlighterJS is written in MooTools. Requires MooTools v1.4+ (included) and client enabled javascript

Shortcode Quickstart Example

Highlight javascript code (theme defined on your settings page)

window.addEvent('domready', function(){
    console.info('Hello Enlighter');

Inline Syntax Highlighting with Shortcode

Lorem ipsum dolor sit amet, [js]window.alert('Hello World');[/js] consetetur sadipscing elitr,
sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua.

Point out special lines of code

Shortcode Style Just add the highlight attribute with the lines you wish to point out

[js highlight="2"]
window.addEvent('domready', function(){
    console.info('Hello Enlighter');

Visual Editor You have to edit the generated html tag by switching to Text-Mode

<pre class="EnlighterJSRAW" data-enlighter-language="js" data-enlighter-highlight="2">
    window.addEvent('domready', function(){
        console.info('Hello Enlighter');

Codegroup Example

Display multiple codes within a tab-pane. You can define a custom tab-pane title for each snippet if you want.

    [js tab="Javascript Message"]
    window.addEvent('domready', function(){
        // display string on console
        console.info('Hello Enlighter');

        // show element

    <div id="myelement">

    [css tab="Styling"]
        color: #cc2222;
        padding: 15px;
        font-size: 20px;
        text-align: center;     

Legacy Example

It's also possible to use the plugin with legacy shortcode (disabled language shortcodes)

[enlighter lang="js"]
window.addEvent('domready', function(){
    // display string on console
    console.info('Hello Enlighter');

    // show element

Supported Languages (build-in) + Shortcodes

  • HTML [html]
  • CSS (Level 1, 2, 3) [css]
  • XML [xml]
  • Javascript [js, javascript]
  • Java [java]
  • Markdown [md]
  • PHP [php]
  • Python [python]
  • Ruby [ruby]
  • Shellscript [shell]
  • C [c]
  • C++ [cpp]
  • C# [csharp]
  • SQL [sql]
  • NSIS [nsis]
  • DIFF [diff]
  • RAW Code [raw]
  • Unhighlighted Code [no-highlight]

Translations (I18n)

Please keep in mind that not all translations are up to date. You are welcome to contribute!

  • English (default)
  • German (de_DE by Andi Dittrich)
  • Serbo-Croatian (sr_RS by Borisa Djuraskovic from webhostinghub.com)

Related Links

Requires: 3.9 or higher
Compatible up to: 4.1.1
Last Updated: 2015-1-24
Active Installs: 1,000+


4.4 out of 5 stars


Got something to say? Need help?


Not enough data

1 person says it works.
0 people say it's broken.

100,2,2 100,1,1
100,1,1 100,1,1
100,1,1 100,1,1
100,1,1 100,1,1
100,1,1 100,1,1
100,1,1 100,1,1