Skip to content


Subversion checkout URL

You can clone with
Download ZIP


sectore edited this page · 149 revisions

The Jekyll plugin system hooks allow you to create custom generated content specific to your site. You can run custom code for your site without having to modify the Jekyll source itself.

Installing a plugin

In your site source root, make a _plugins directory. Place your plugins here. Any file ending in *.rb inside this directory will be required when Jekyll generates your site (unless the configuration option Safe is set).

In general, plugins you make will fall into one of three categories:

1. Generators
2. Converters
3. Tags


You can create a generator when you need Jekyll to create additional content based on your own rules. For example, a generator might look like this:

module Jekyll

  class CategoryPage < Page
    def initialize(site, base, dir, category)
      @site = site
      @base = base
      @dir = dir
      @name = 'index.html'

      self.read_yaml(File.join(base, '_layouts'), 'category_index.html')['category'] = category

      category_title_prefix = site.config['category_title_prefix'] || 'Category: '['title'] = "#{category_title_prefix}#{category}"

  class CategoryPageGenerator < Generator
    safe true
    def generate(site)
      if site.layouts.key? 'category_index'
        dir = site.config['category_dir'] || 'categories'
        site.categories.keys.each do |category|
          site.pages <<, site.source, File.join(dir, category), category)


In this example, our generator will create a series of files under the `categories` directory for each category, listing the posts in each category using the `category_index.html` layout.

Generators are only required to implement one method:

1. generate: string output of the content being generated


If you have a new markup language you’d like to include in your site, you can include it by implementing your own converter. Both the markdown and textile markup languages are implemented using this method. Please note that Jekyll will only convert files that also have a YAML header at the top. If there is no YAML header at the top of the file, Jekyll will ignore it and not send it through the converter.

Below is a converter that will take all posts ending in .upcase and process them using the UpcaseConverter:

module Jekyll
  class UpcaseConverter < Converter
    safe true

    priority :low

    def matches(ext)
      ext =~ /upcase/i

    def output_ext(ext)

    def convert(content)

Converters should implement at a minimum 3 methods:

1. matches: Called to determine whether the specific converter will run on the page.
2. output_ext: The extension of the outputted file, usually “.html”
3. convert: Logic to do the content conversion

In our example, UpcaseConverter#matches checks if our filename ends in the word ‘upcase’, and will render using the converter if it does. It will call UpcaseConverter#convert to process the content – in our simple converter we’re simply capitalizing the entire content string. Finally, when it saves the page, it will do so with the .html extension.


If you’d like to include custom liquid tags in your site, you can do so by hooking into the tagging system. Built-in examples from jekyll include the ‘highlight’ and the ‘include’ tag.

As an example, here is a custom liquid tag that will output the time the page was rendered:

module Jekyll
  class RenderTimeTag < Liquid::Tag

    def initialize(tag_name, text, tokens)
      @text = text

    def render(context)
      "#{@text} #{}"

Liquid::Template.register_tag('render_time', Jekyll::RenderTimeTag)

At a minimum, liquid tags must implement:

1. render: Outputs the content of the tag

You must also register the custom liquid tag with the Liquid templating system by calling:

Liquid::Template.register_tag('render_time', Jekyll::RenderTimeTag)

In the example above, we can place the following tag anywhere in one of our pages:

{% render_time page rendered at: %}

And we would get something like this on the page:

page rendered at: Tue June 22 23:38:47 -0500 2010

Liquid filters

You can add your own filters to the liquid system much like you can add tags above. Filters are simply modules that export their methods to liquid. All methods will have to take at least one parameter which represents the input of the filter. The return value will be the output of the filter.

module Jekyll
  module AssetFilter
    def asset_url(input)      


Advanced: you can access the site object through the @context.registers feature of liquid. Registers a hash where arbitrary context objects can be attached to. In Jekyll you can access the site object through registers. As an example, you can access the global configuration (_config.yml) like this: @context.registers[:site].config['cdn'].


There are two flags to be aware of when writing a plugin:

1. safe: boolean that allows a plugin to be run in safe mode. However, site specific plugins loaded from the _plugins directory (in contrast to Jekyll wide plugins included in your Jekyll core) will never be run under safe mode. So in most cases, you don’t need to worry about this.
2. priority: determines what order the plugin is loaded in. Valid values are: :lowest, :low, :normal, :high, :highest

Available Plugins

There are a few useful, prebuilt plugins at the following locations:

  1. Truncate HTML while preserving markup structure by Matt Hall
  2. Generic Blog Plugins by Jose Diaz-Gonzalez : Contains plugins for tags, categories, archives, as well as a few liquid extensions
  3. Domain Name Filter by Lawrence Woodman : Filters the input text so that just the domain name is left
  4. Jekyll Plugins by Recursive Design : Plugin to generate Project pages from github readmes, a Category page plugin, and a Sitemap generator
  5. Tag Cloud Plugin from a Jekyll walk-through : Plugin to generate a Tag Cloud
  6. Pygments Cache Path by Raimonds Simanovskis : Plugin to cache syntax-highlighted code from Pygments
  7. Delicious Plugin by Christian Hellsten : Fetches and renders bookmarks from
  8. Ultraviolet plugin by Steve Alex : Jekyll Plugin for Ultraviolet
  9. HAML plugin by Sam Z : HAML plugin for jekyll
  10. ArchiveGenerator by Ilkka Laukkanen : Uses this archive page to generate archives
  11. Tag Cloud Plugin by Ilkka Laukkanen : Jekyll tag cloud / tag pages plugin
  12. HAML/SASS Converter by Adam Pearson : Simple haml-sass conversion for jekyll. Fork by Sam X
  13. SASS scss Converter by Mark Wolfe : Jekyll Converter which uses the new css compatible syntax, based on the one written by Sam X.
  14. GIT Tag by Alexandre Girard : Jekyll plugin to add Git activity inside a list
  15. Draft/Publish Plugin by Michael Ivey
  16. Less.js generator by Andy Fowler : Jekyll plugin to render less.js files during generation.
  17. Less Converter by Jason Graham : A Jekyll plugin to convert a .less file to .css
  18. Less Converter by Josh Brown
  19. MathJax Liquid Tags by Jessy Cowan-Sharp : A simple liquid tag for Jekyll that converts {% m } and { em } into inline math, and { math } and { endmath %} into block equations, by replacing with the appropriate MathJax script tags.
  20. Non-JS Gist Tag by Brandon Tilley A Liquid tag for Jekyll sites that allows embedding Gists and showing code for non-JavaScript enabled browsers and readers.
  21. Growl Notification Generator by Tate Johnson
  22. Growl Notification Hook by Tate Johnson : Better alternative to the above, but requires his “hook” fork.
  23. Version Reporter by Blake Smith
  24. Upcase Converter by Blake Smith
  25. Render Time Tag by Blake Smith
  26. Summarize Filter by Mathieu Arnold
  27. Tag by phaer
  28. CoffeeScript converter by phaer : Put this file in _plugins/ and write a YAML header to your .coffee files (i.e. "---\n---\n"). See for more info
  29. Raw Tag by phaer. : Keeps liquid from parsing text betweeen {% raw } and { endraw %}
  30. URL encoding by James An
  31. Sitemap.xml Generator by Michael Levin
  32. Markdown references by Olov Lassus : Keep all your markdown reference-style link definitions in one file (
  33. Full-text search by Pascal Widdershoven : Add full-text search to your Jekyll site with this plugin and a bit of JavaScript.
  34. Stylus Converter Convert .styl to .css.
  35. client by Robert Böhnke Autogenerate embeds from URLs using oEmbed.
  36. Logarithmic Tag Cloud : Flexible. Logarithmic distribution. Usage eg: {% tag_cloud font-size: 50 – 150%, threshold: 2 %}. Documentation inline.
  37. Related Posts by Lawrence Woodman : Overrides site.related_posts to use categories to assess relationship
  38. AliasGenerator by Thomas Mango : Generates redirect pages for posts when an alias configuration is specified in the YAML Front Matter.
  39. FlickrSetTag by Thomas Mango : Generates image galleries from Flickr sets.
  40. Projectlist by Frederic Hemberger : Loads all files from a directory and renders the entries into a single page, instead of creating separate posts.
  41. Tiered Archives by Eli Naeher : creates a tiered template variable that allows you to create archives grouped by year and month.
  42. Jammit generator by Vladimir Andrijevik : enables use of Jammit for JavaScript and CSS packaging.
  43. oEmbed Tag by Tammo van Lessen : enables easy content embedding (e.g. from YouTube, Flickr, Slideshare) via oEmbed.
  44. Company website and blog plugins by Flatterline, a Ruby on Rails development company : portfolio/project page generator, team/individual page generator, author bio liquid template tag for use on posts and a few other smaller plugins.
  45. Transform Layouts Monkey patching allowing HAML layouts (you need a HAML Converter plugin for this to work)
  46. ReStructuredText converter : Converts ReST documents to HTML with Pygments syntax highlighting.
  47. Tweet Tag by Scott W. Bradley : Liquid tag for Embedded Tweets using Twitter’s shortcodes
  48. jekyll-localization : Jekyll plugin that adds localization features to the rendering engine.
  49. jekyll-rendering : Jekyll plugin to provide alternative rendering engines.
  50. jekyll-pagination : Jekyll plugin to extend the pagination generator.
  51. jekyll-tagging : Jekyll plugin to automatically generate a tag cloud and tag pages.
  52. Generate YouTube Embed by joelverhagen : Jekyll plugin which allows you to embed a YouTube video in your page with the YouTube ID. Optionally specify width and height dimensions. Like “oEmbed Tag” but just for YouTube.
  53. Lazy and responsive Youtube video : a Jekill or Octopress plugin to embed YouTube video into your blog. Plugin has been optimized to delay the creation of , allowing many embedded videos in a single page without performance lost.
  54. JSON Filter by joelverhagen : filter that takes input text and outputs it as JSON. Great for rendering JavaScript.
  55. jekyll-beastiepress : FreeBSD utility tags for Jekyll sites.
  56. jsonball : reads json files and produces maps for use in jekylled files
  57. redcarpet2 : use Redcarpet2 for rendering markdown
  58. bibjekyll : render BibTeX-formatted bibliographies/citations included in posts/pages using bibtex2html
  59. jekyll-citation : render BibTeX-formatted bibliographies/citations included in posts/pages (pure Ruby)
  60. jekyll-scholar : Jekyll extensions for the blogging scholar
  61. jekyll-asset_bundler : bundles and minifies JavaScript and CSS
  62. Jekyll Dribbble Set Tag : builds Dribbble image galleries from any user
  63. debbugs : allows posting links to Debian BTS easily
  64. refheap_tag : Liquid tag that allows embedding pastes from refheap
  65. i18n_filter : Liquid filter to use I18n localization.
  66. singlepage-jekyll by JCB-K : turns Jekyll into a dynamic one-page website.
  67. flickr : Embed photos from flickr right into your posts.
  68. jekyll-devonly_tag : A block tag for including markup only during development.
  69. Jekyll plugins by Aucor : Plugins for eg. trimming unwanted newlines/whitespace and sorting pages by weight attribute.
  70. Only first paragraph : Show only first paragrpaph of page/post.
  71. jekyll-pandoc-plugin : use pandoc for rendering markdown.
  72. File compressor by mytharcher : Compress HTML and JavaScript(*.js) files when output.
  73. smilify by SaswatPadhi : Convert text emoticons in your content to themeable smiley pics. Demo
  74. excerpts by drawoc : provides a nice way to implement page excerpts.
  75. jekyll-mapping : A (fairly) comprehensive solution for embedding maps (both complex and simple) on Jekyll sites.
  76. jekyll-category-list : A CSS3 animated category list
  77. Garmin-tag : A tag for embedding Garmin activity iframes into your posts
  78. jekyll-json : Turn YAML config into JSON, for easy use in JavaScript. Will take sitewide defaults from _config.yml, and then apply page specific specifics over the top of this.
  79. jekyll-models : Make your own page objects like posts that use templates to generate a page for each one. These objects can hold any yaml you want. Have them generated into REST-like paths too.
  80. jekyll-sort : Sort lists (of hashes or primitives) under the site var and store the results back under the site var.
  81. jekyll-thumbnailer : Image thumbnailing plugin for Jekyll / octopress
  82. jekyll-slideshow : Slideshows in Jekyll. Makes it super easy for you to include image slideshows within your content – includes the JavaScript for the slideshows, and produces the thumbnail images for you.
  83. jekyll-prism-plugin : Replaces Pygments syntax highlighting with PrismJS.
  84. jekyll-js-minify-plugin : Minifies all Javascript files using Google Closure Compiler. Extremely simple, no configuration. Just drop it in.
  85. jekyll-press : Minifies all html, js, css files. No Java required. Simple. Just drop it in.
  86. jekyll-ditaa by Matthias Vogelgesang : Generates diagram images from ditaa markup blocks.
  87. jekyll-vimeo-plugin : Embed videos from Vimeo by using a Liquid tag.
  88. Jekyll Buildpack : Compile LESS, combine/uglify JS, copy files — Twitter Bootstrap friendly
  89. jekyll-soundcloud : A simple plug-in for embedding SoundCloud sounds in your Liquid templates.
  90. jekyll-flickr : A simple plug-in for embedding individual Flickr photos in your Liquid templates. Grabs multiple sizes and EXIF data as well.
  91. jekyll_oembed : Similar to oEmbed Tag by Tammo van Lessen, but supports additional params. For example, width for Vimeo.
  92. jekyll-emoji : Provides a Liquid filter for emojifying text via Gemmoji. See Emoji Cheat Sheet for a full listing of emoji codes.
  93. jekyll-author : Plugin to generate listing of posts by author. Also provides a Liquid filter for adding links for author to the listing page.
  94. epub-jekyll : A script (not quite a plugin) to generate an EPUB e-book from Jekyll posts and pages.
  95. jekyll-assets : Rails-alike assets pipelines for Jekyll
  96. jekyll-evernote_rss : Plugin for public Evernote notebook integration
  97. Hierarchical Categories : Append a hierarchical list of categories and posts to the Site object
  98. Time Ago In Words : A filter for converting Time into a human-readable format, just like the helper method in rails by the same name.
  99. Jekyll Asset Pipeline : Powerful asset pipeline for Jekyll that collects, converts and compresses JavaScript and CSS assets
  100. WP-to-Jekyll : full conversion with WP-like stack – javascript search, auto archive and category pages, audio tag filter, even scripts to push to EC2 pretty easily. Also a rake task for deployment.
  101. jekyll-minibundle : A minimalistic plugin for bundling and stamping assets, requiring only your bundling tool of choice, no other dependencies.
  102. jekyll_zeit : A plugin for including content from german newspaper “Die Zeit”/“Zeit online”
  103. gallery : a script (not quite a plugin) to generate a photo gallery
  104. jekyll-swfobject : A plugin for embedding Flash files (*.swf) by using SWFObject
Something went wrong with that request. Please try again.