BoxLang, compiled to Rust.
Ships to a native binary.
BoxLang is the platform, and MatchBox is its Rust runtime, alongside the JVM one. Same language, with a bytecode VM and a tiered Cranelift JIT, for native, browser, WASI, AWS Lambda and ESP32.
$ curl -fsSL https://raw.githubusercontent.com/ortus-boxlang/matchbox-quick-installer/main/install/install.sh | bashMatchBox, running in this tab.
No install and no server. This is a real MatchBox VM compiled to WebAssembly. Click an example or type your own BoxLang.
Ten short lessons, nothing to install.
Learn the language and ship your first binary. Every code sample has a Run button that opens a real MatchBox runtime right under it, so you can change the code and run it again.
- 1Welcome to MatchBoxWhat it is, and your first script.
- 2Install and runMVM, running and compiling a file.
- 3Values and stringsVariables, interpolation, operators.
- 4Arrays and structsLists, key-value data and loops.
- 5Functions and callbacksArrow functions, map, filter, reduce.
- 6Classes and objectsState, constructors and chaining.
- 7Errors and control flowif, switch, try, catch, finally.
- 8Running work at the same timeFutures, runAsync and then.
- 9Build and shipA native executable, or bytecode.
- 10Where to go nextTargets, Native Fusion, and gotchas.
BoxLang on the JVM. BoxLang on Rust.
MatchBox does not replace the JVM runtime. It complements it. Write BoxLang once, then choose the runtime that fits where the code has to run.
BoxLang on the JVM
The full Java ecosystem, broad module coverage, and the infrastructure your JVM apps already use.
Choose it for Java interop and the full library surfaceMatchBox, on Rust
Single binaries, browser and edge, containers, serverless and microcontrollers, with no JVM at runtime.
Choose it to run BoxLang where a JVM does not fitMatchBox is an independent, evolving implementation. Runtime APIs and module support differ between the two, so check compatibility for your target.
Agents already speak MatchBox.
MatchBox is part of the BoxLang productivity platform, where developers and AI agents work in the same loop. Install the skills once and your agent knows the targets, the commands and the limits.
From source to machine code.
Your BoxLang compiles to bytecode. A Rust VM runs it, schedules fibers, and the native CLI compiles hot code with Cranelift.
It watches your code, then compiles what is hot.
Four tiers of JIT, built on Cranelift. Cheap profiling first, native machine code only once a loop or function has earned it.
Fibers share one thread, politely.
runAsync, sleep and HTTP yield to a cooperative scheduler, so other fibers keep running while one waits.
A tiny runtime, plus your code. One file.
MatchBox compiles your BoxLang to bytecode and appends it to a stripped runner stub. Nothing else to install on the destination.
.bxb bytecode file to any compatible runner, or strip the source text with --strip-source.runAsync and non-blocking sleep and HTTP without OS thread overhead.Run it close to the workload.
One codebase. Pick the destination at build time.
What each target brings with it.
Targets share the language, not every capability. Here is the honest picture, straight from the compatibility guide.
A high level orientation, not a guarantee for every release or build. Test the artifact on the destination.
BoxLang, Rust and Java, in one loop.
Call Rust from BoxLang. Let Rust call back into BoxLang. Reach Java classes from a native build. Tap an arrow to see it.
Built for BoxLang, with BoxLang.
MatchBox is one runtime in a wider platform. These projects work alongside it.
Need MatchBox in production? Talk to the people who build BoxLang.
Ortus Solutions offers professional support, architecture reviews and custom development for BoxLang, including native tools, edge and WASM workloads, and embedded devices.
Install it. Run a script. Ship a binary.
Three steps. MVM, the MatchBox Version Manager, installs MatchBox for you and keeps versions side by side.
Install MVM
Run the installer for your system, then open a new terminal.
Linux and macOS$ curl -fsSL https://raw.githubusercontent.com/ortus-boxlang/matchbox-quick-installer/main/install/install.sh | bashWindows PowerShell> irm https://raw.githubusercontent.com/ortus-boxlang/matchbox-quick-installer/main/install/install.ps1 | iexInstall MatchBox
Install the latest stable release and switch to it. If
matchboxis not found, runmvm doctor.$ mvm install latest && mvm use latest$ matchbox --versionRun your first script
Save
println( "Hello, MatchBox!" );in a file calledhello.bxs, run it, then build it into a single native executable.$ matchbox hello.bxs$ matchbox --target native hello.bxs
Not ready to install? Try MatchBox in your browser or take the course. Review an installer before you run it if you prefer: both scripts are in the MVM repository.
Straight answers.
What is MatchBox?
MatchBox is a Rust implementation of the BoxLang runtime. BoxLang is the platform, and it now has two runtimes: the JVM runtime and MatchBox on Rust. MatchBox compiles BoxLang to bytecode and runs it on a Rust VM with a tiered JIT in the native CLI.
Is MatchBox a replacement for BoxLang on the JVM?
No. It complements it. Use the JVM runtime for the full Java ecosystem and broad module coverage. Use MatchBox to run BoxLang where a JVM does not fit, such as single binaries, the browser, WASI containers, serverless and microcontrollers. Runtime APIs and module support differ, so check compatibility for your target.
Does MatchBox need a JVM?
No, not for the core runtime or for native builds. Experimental Java interop exists in native builds and needs a JDK on the machine.
Where can MatchBox run?
Native executables, the browser and JavaScript (including Cloudflare Workers), WASI containers, AWS Lambda (preview) and ESP32 devices.
How do I install it?
Install MVM, the MatchBox Version Manager, then run mvm install latest && mvm use latest. See the installation guide.
Can AI agents write MatchBox code?
Yes. Install the BoxLang skills with npx skills add ortus-boxlang/skills and your agent learns the targets, commands and limits. This site also publishes an llms.txt index and an MCP endpoint.