Top Best Syntax Highlighter WordPress Plugins

Do you want to insert code snippets into your WordPress posts? Your best bet is to use a syntax highlighter plugin. Here’s the best one I’ve found:

1. Code Snippets CPT

A WordPress plugin for elegantly hosting, managing, and displaying code snippets. Own your own data! Adds a custom post type for managing your code snippets with taxonomies for classifying the snippets. Embed snippets with syntax highlighting to posts or pages via a handy shortcode insert button that allows you to pick from the most recent snippets. Syntax highlighting provided by the Prettify javascript library and the Ace Editor.


2. WP-Syntax

WP-Syntax provides clean syntax highlighting using GeSHi — supporting a wide range of popular languages. It supports highlighting with or without line numbers and maintains formatting while copying snippets of code from the browser.


3. Enlighter – Customizable Syntax Highlighter

Enlighter is a free, easy-to-use, syntax highlighting tool for WordPress. It’s built 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.


4. Prismatic

Prismatic gives you three options for displaying code: Prism.js, Highlight.js, and Plain. The first two use their own respective libraries, while the third displays code without any syntax highlighting (allowing you to customize the way it looks). The plugin focuses on being lightweight and only loads CSS/JS when needed.


5. Code Prettify

Uses the Google Code Prettify library that is minified and properly enqueued. Plugin applies code highlighting automatically to all <pre> and <code> tags on the page.


6.Better File Editor

Adds line numbers, syntax highlighting, code folding, and lots more to the theme and plugin editors in the admin panel. This plugin replaces the boring, clunky, and difficult to use theme and plugin editor with a full-featured code editor using the Cloud9 Editor.


7. HTML Editor Syntax Highlighter

Add syntax highlighting in the WordPress Post & Page HTML text editor and the Theme & Plugin editors using Codemirror.js

Leave a reply