programmingweb dev

Kept in this browser · My desk

Stands for: Perl Compatible Regular Expressions

A C library of regular-expression functions with Perl's syntax and semantics, now in its second API, PCRE2, and the engine behind the regular expressions of NGINX, PHP and many other programs.

Philip Hazel wrote it at the University of Cambridge's computing service. PCRE2 is the revised API, forked from PCRE1, and the old library is obsolete and no longer maintained. NGINX needs it for regular expressions in location blocks and the rewrite module, and since 1.21.5 uses PCRE2 unless built with --without-pcre2. Its default dialect follows Perl 5, with options that come closer to JavaScript or Python, so a pattern tested in a browser can behave differently once it is in an NGINX location.

Also known as: pcre2, pcre1, perl compatible regular expressions

← Back to P Back to the glossary