Gleam is production ready for BEAM and JavaScript teams
Gleam offers a type-safe way to bridge the BEAM and JavaScript runtimes. In testing, John Mikael Lindbakk ran a site handling 2000 requests per second on a single CPU core using only 210 MB of memory.
The shift to full-stack capability
I find Gleam production ready for teams that want to bridge the BEAM and JavaScript runtimes. The language reached version 1.0 in March 2026, which ensures backward compatibility through semantic versioning. Louis Pilfold, the core maintainer, designed Gleam to target both the Erlang virtual machine and JavaScript. Because the compiler targets the Erlang virtual machine, a team writing a backend web API in Gleam can choose to also write their website frontend in Gleam, sharing code between both platforms. The Erlang virtual machine is second to none for long-running services that run on servers. Outside of this space, JavaScript has strong concurrency features and respectable single-threaded performance thanks to highly optimized runtimes like Google’s V8 engine. John Mikael Lindbakk ran a website on Gleam for six months without outages. His site handled 2000 requests per second on a single CPU core while using 210 MB of memory. This usage sits well below the 512 MB memory limit he set for the application. The ecosystem lacks maturity though. Many packages have not reached version 1.0, and some dependencies introduce breaking changes. Elixir is the most mature and popular alternative to Erlang on BEAM, providing a Ruby-like syntax and a dynamical type system. Gleam is the only one among competitors like Alpaca and Caramel that also targets JavaScript.
| Specification | Value |
|---|---|
| Current Version | 1.17.0 |
| Throughput | 2000 requests/second |
| Memory Usage | 210 MB |
| Memory Cap | 512 MB |
| Gleam Packages | < 600 |
| Hex Packages | ~16,000 |
Pattern matching and developer tooling
The language implementation in Rust provides a specific type of developer experience. I appreciate how the compiler uses exhaustiveness checking to catch missing pattern match arms. If a developer forgets a value in a custom data type, the compiler produces an error. Gleam supports structural pattern matching on the contents of a string or a list. It also allows matching on multiple values. You can use shadowing to provide ergonomic ways to update immutable data structures. This prevents race conditions. The language server, which developers have used since 2022, provides features like document highlighting and record update information. Contributors like Giacomo Cavalieri and Gavin Morrow work on improving these tools. The compiler also supports fault tolerant compilation to help the language server provide info even when code is invalid. In the latest release, the compiler includes a feature to provide context aware type printing in warnings. This helps developers when the type is aliased or qualified. You might find the lack of loops frustrating if you come from an imperative background. The absence of loops and early returns makes certain tasks harder. A developer must use recursion to achieve the behavior of a loop. Writing a factorial function requires a private function with a different interface to leverage tail call optimization. This makes the code harder to read than an imperative loop.
Interoperability and the package ecosystem
Gleam relies on the Erlang ecosystem for its strength. The language build tool compiles Elixir dependencies and source files, which allows developers to mix Erlang and Elixir code into Gleam programs. This integration works because the build tool can compile Elixir source files and import external functions. The Gleam package repository contains under 600 packages. This number is small when you compare it to the 16,000 packages available on Hex. You need Erlang installed to run compiled Gleam code on the BEAM. In the JavaScript world, developers use bundlers to combine modules, but Erlang has a similar solution called escripts. The latest version, 1.17.0, includes a command to create an escript, which compiles the project and builds a single file containing all modules. This is helpful for sharing small command-line programs. The compiler produces error messages similar to Rust, which helps you reach your goal without null values or exceptions. Gleam also includes keywords like todo and panic! to handle incomplete code or errors. The compiler produces a warning whenever it finds a todo expression during compilation. Can the community expand the package count fast enough to match Elixir?