Onigmo Introduction

This page contain technical information about the Onigmo regular expression library. It is our preferred regular expression engine for Notepad3.

Onigmo (Oniguruma-mod) is a BSD licensed regular expression library that supports a variety of character encoding. It is forked from Oniguruma (鬼車) by K. Kosako. It focuses to support new expressions like \K, \R, (?(cond)yes|no) and etc. which are supported in Perl 5.10+. Ruby since version 2.0 has also switched to it and features have been back ported from ruby to Onigmo.

For a complete Onigmo syntex reference click here. Or read Fundamental Regular Expression Examples by the incredible LH_Mouse to learn by example.


The Ruby programming language, in version 1.9, as well as PHP’s multi-byte string module (since PHP5), use Oniguruma as their regular expression engine. It is also used in products such as Atom, GyazMail Take Command Console, Tera Term, TextMate, Sublime Text and SubEthaEdit. Oniguruma is Japanese for “Oni’s Chariot”.

The characteristics of the Oniguruma library is that different character encoding for every regular expression object can be specified.

Supported character encoding:

ASCII, UTF-8, UTF-16BE, UTF-16LE, UTF-32BE, UTF-32LE, EUC-JP, EUC-TW, EUC-KR, EUC-CN, Shift_JIS, Big5, GB18030, KOI8-R, CP1251, ISO-8859-1, ISO-8859-2, ISO-8859-3, ISO-8859-4, ISO-8859-5, ISO-8859-6, ISO-8859-7, ISO-8859-8, ISO-8859-9, ISO-8859-10, ISO-8859-11, ISO-8859-13, ISO-8859-14, ISO-8859-15, ISO-8859-16

  • GB18030: contributed by KUBO Takehiro
  • CP1251: contributed by Byte