Comparison
Mikro.js is built for hobbyists, tinkerers, and DIY fanatics. Here's how it compares to other options for programming microcontrollers.
Overview
| Mikro.js | Arduino | MicroPython | CircuitPython | Espruino | Moddable (XS) | |
|---|---|---|---|---|---|---|
| Language | TypeScript | C/C++ | Python 3 subset | Python 3 subset | JavaScript | JavaScript |
| Type checking | Full (TypeScript) | Full (static) | Optional hints | None | None | Experimental TS |
| Live reload | Yes | No | No | Auto-reload | REPL | No |
| Error handling | Typed Results | Manual | Exceptions | Exceptions | Exceptions | Exceptions |
| JS engine | QuickJS-NG | N/A | N/A | N/A | Custom | XS |
| ESP32 support | Yes | Yes | Yes | Partial | Yes | Yes |
| Module system | ES modules | Arduino libs | Python imports | Python imports | CommonJS | ES modules |
ECMAScript support
For the JavaScript-based runtimes, here's how their ES spec coverage compares:
| Mikro.js (QuickJS-NG) | Espruino | Moddable (XS) | |
|---|---|---|---|
| ES2015 (ES6) | Full | Partial | Full |
| ES2016–ES2020 | Full | Minimal | Full |
| ES2021–ES2023 | Full | No | Full |
| ES2024 | Mostly | No | Partial |
| Modules | ES modules | Custom | ES modules |
| Intl APIs | No | No | No |
| Async/await | Yes | Yes | Yes |
| Proxy/Reflect | Yes | No | Yes |
Mikro.js uses QuickJS-NG, which passes ~98% of language tests and ~82% overall on test262 (the gap is mostly Intl and Temporal APIs, omitted due to code size constraints).
vs Arduino (C/C++)
Arduino is one of the most popular microcontroller platforms. It's fast and has a large library ecosystem, but the development cycle can be slow: edit, compile, flash, test. A simple change can take 30+ seconds to verify.
Mikro.js advantages:
- Live reload: save a file, typically see results in seconds
- TypeScript can catch many bugs before they reach the device
- No manual memory management
- Familiar web developer tooling (npm, ES modules)
Arduino advantages:
- Best performance (native code)
- Lower memory overhead
- Very large library ecosystem
- Broad hardware support
Choose Arduino when you need raw performance, real-time guarantees, or access to a specific C library. Choose Mikro.js for hobby and DIY projects where you want fast iteration and type safety, and the performance overhead of a JS engine is acceptable.
vs MicroPython
MicroPython runs Python 3 on microcontrollers. It has broad hardware support and a REPL for interactive development.
Mikro.js advantages:
- Full TypeScript type checking; MicroPython's type hints are optional and less common on MCUs
- Typed error handling (Results vs exceptions)
- Live reload over serial; MicroPython typically requires manual file transfer or tools like Thonny
- ES modules with tree-shaking potential
MicroPython advantages:
- Supports more hardware (STM32, RP2040, nRF, etc.)
- Larger community and more driver libraries
- Python is widely known
- Mature REPL for interactive experimentation
Choose MicroPython if you need hardware Mikro.js doesn't support, or you prefer Python. Choose Mikro.js if you want type safety and a faster edit-run cycle on ESP32.
vs CircuitPython
CircuitPython is Adafruit's fork of MicroPython, focused on beginner-friendliness. Code saves directly to a USB drive; the board auto-reloads.
Mikro.js advantages:
- TypeScript type checking can catch errors before runtime
- Typed Results instead of exceptions
- Richer IDE support (autocomplete, inline errors)
CircuitPython advantages:
- 260+ curated Adafruit libraries
- Drag-and-drop workflow (USB mass storage)
- Excellent beginner documentation and tutorials
- Broad board support (Adafruit, RP2040, nRF)
Choose CircuitPython if you're teaching beginners or using Adafruit hardware. Choose Mikro.js if you prefer TypeScript and typed error handling on ESP32.
vs Espruino
Espruino runs a custom JavaScript engine on microcontrollers. Development is REPL-driven: type code, see it execute immediately.
Mikro.js advantages:
- TypeScript with full type checking; Espruino is untyped JS
- ES2024 support (QuickJS-NG); Espruino supports older JS
- ES modules; Espruino uses a custom module system
- Typed Results; Espruino uses exceptions
Espruino advantages:
- True interactive REPL (type and execute line by line)
- Can run on very small devices (128KB flash, 8KB RAM)
- Bluetooth/wearable focus (Puck.js, Bangle.js)
- Web-based IDE
Choose Espruino for Bluetooth wearables or when you want a fully interactive REPL. Choose Mikro.js if you want TypeScript, modern JS, and a structured project workflow.
vs Moddable SDK (XS)
Moddable provides a full SDK with the XS JavaScript engine, targeting IoT products.
Mikro.js advantages:
- First-class TypeScript (Moddable has experimental TypeScript support)
- Live reload (Moddable uses compile-and-flash)
- npm-based tooling; Moddable uses its own build system
- Typed Result errors; Moddable uses exceptions
Moddable advantages:
- Integrated source-level debugger (xsbug)
- More mature network protocol stack (MQTT, mDNS, BLE)
- Designed for commercial IoT products
- Broader protocol support
Choose Moddable for production IoT products that need MQTT, BLE, or their debugger. Choose Mikro.js if you want TypeScript, live reload, and npm-based tooling.
vs Embedded Rust, MicroZig, Embedded Swift
These are compiled-to-native languages targeting microcontrollers. They occupy a different point in the design space than Mikro.js: they prioritize runtime performance and memory safety over development speed.
Embedded Rust has a growing ecosystem for bare-metal and RTOS-based development. It offers strong memory safety guarantees at compile time, zero-cost abstractions, and no garbage collector. The tradeoff is a steeper learning curve and slower iteration: every change requires a full compile-and-flash cycle.
MicroZig brings Zig to microcontrollers with a focus on simplicity and C interop. It's less mature than Embedded Rust but appeals to developers who find Rust's borrow checker too restrictive.
Embedded Swift is Apple's emerging effort to bring Swift to bare-metal targets. It's still early, with limited hardware support and tooling.
All three produce native binaries with minimal runtime overhead, making them better suited for hard real-time requirements, safety-critical applications, or extreme memory constraints. Mikro.js trades some runtime performance for a faster development loop: live reload, no compile step, and a language most web developers already know. If your project needs the guarantees of a systems language, these are strong options. If you're a hobbyist or tinkerer who values a great developer experience over raw performance, Mikro.js may be a better fit.