WasmCoffee
Compile and Run Java-Inspired Code in WebAssembly (Wasm-GC) Directly in the Browser
Try WasmCoffee Live
Experience the complete in-browser IDE, multi-file compiler, real-time diagnostics, Canvas 2D graphics, and standalone exports.
Open wasmcoffee.com →What is WasmCoffee?
WasmCoffee is an in-browser compiler and developer environment written from scratch in the Odin programming language. It compiles source code written in modern Java-inspired syntax directly to WebAssembly (Wasm-GC) bytecode inside the browser and runs the freshly emitted binary immediately on the same page.
There is no JVM to install, no heavyweight download, no server-side compilation step, and no filesystem
dependencies.
The compiler runs inside an off-thread Web Worker, emitting native Wasm-GC opcodes (such as
struct.new,
array.new_fixed, and ref.test) that execute natively in modern browser
JavaScript and WebAssembly engines.
Highlights & Capabilities
⚡ 100% In-Browser Wasm-GC
The compiler runs client-side inside a Web Worker. Lexing, parsing, type-checking, and Wasm-GC bytecode emission happen in milliseconds, never freezing your editor or the 60 FPS animation loop.
☕ Modern Java Language Subset
Accepts modern Java features: record types with record pattern matching (JEP 440),
unnamed variables and patterns _ (JEP 456), sealed classes and
interfaces with permits, switch expressions, generics, lambdas, and method
references.
📚 Collections & Standard Library
Includes modular library support via import module java.base; (JEP 511),
ArrayList, HashMap, HashSet, List.of,
StringBuilder, Arrays.sort, and high-precision monotonic timing with
System.nanoTime().
🎮 Canvas 2D & Direct Memory Blitting
High-performance graphics via direct linear memory pixel manipulation
(Memory.base(), Memory.put32()) with zero-copy 60 FPS
putImageData blitting, alongside a full HTML5 Canvas 2D bridge (arc,
fillRect, beginPath, requestFrame).
🚀 Four-Way Standalone Exports
Export projects as standalone artifacts with a single click: grab the compiled
.wasm binary, the full source project as a .zip, a ready-to-deploy
static web application, or a single self-contained .html file that runs straight
off disk without a server.
💻 CodeMirror 6 Editor & Diagnostics
Full-featured tabbed multi-file editor with syntax highlighting, bracket matching, line numbers, auto-indent, and clickable compiler diagnostics that jump the cursor straight to error spans.
Interactive Demos & Learning
See WasmCoffee in action through interactive games and structured learning resources:
More In-Browser Compilers
Prefer Pascal over Java? WasmPascal is the sibling project: an in-browser Pascal IDE and compiler written in Odin that compiles Pascal source directly to WebAssembly on the same page.
Ready to write some WebAssembly?
Launch the playground and explore interactive demos like Java Maze, Canvas Snake, ray tracers, and sorting visualizations.
Visit wasmcoffee.com →