Perl in WebAssembly

Perl (Practical Extraction and Reporting Language) was the lingua franca of the early web. A powerful scripting language, it became a popular way to write CGI.

Larry Wall, its creator, once called it the “first post-modern programming language” because it was driven more by a desire to add the things developers liked than to follow specific academic strictures. Its regular expressions have lived on, influencing the designs of countless other programming languages.

Available Implementations

There is no official Perl distribution that is WebAssembly-capable.

The WebPerl project provides a browser-centered Perl interpreter in Wasm. Build instructions support Perl 5.26 and newer.

WebPerl does not provide a WASI implementation, and does not appear to be runnable outside of a browser. But the maintainer has suggested he’d like to add WASI support.


WebPerl describes usage inside of a browser.

Pros and Cons

Things we like:

  • The project supports a tremendous number of features, including a way to bundle PMs.
  • The project is impressively well thought out
  • Documentation covers a wide variety of cases and uses
  • There is even a sample IDE

Things we’re not big fans of:

  • It runs only in the browser
  • The project seems to be stagnant

Learn More

Here are some great resources: