Skip to content
Eugene Lazutkin edited this page Mar 24, 2026 · 22 revisions

Dashboard

Node.js CI NPM version

Release history

About

This project provides Node.js bindings for RE2: a fast, safe alternative to backtracking regular expression engines written by Russ Cox. To learn more about RE2, start with Regular Expression Matching in the Wild. More resources are on his Implementing Regular Expressions page.

RE2's regular expression language is almost a superset of what RegExp provides (see Syntax), but it lacks backreferences and lookahead assertions. See the README for details.

RE2 emulates standard RegExp, making it a practical drop-in replacement in most cases. The constructor accepts RegExp directly, honoring all properties.

It works with Node.js Buffers directly, reducing overhead and making processing of long files fast.

Technical information

At install time, the project downloads a precompiled binary for your platform. It builds from source only if the download fails.

See Precompiled versions.

Troubleshooting

See pages on the right marked with Problem-.

Developers

See Working on this project.

Clone this wiki locally