Skip to main content

Languages

Language support

The languages below can be compiled to WebAssembly with WASI support. Some toolchains produce components built to the Component Model (and can use WASI 0.2 or 0.3), while others produce core Wasm modules (which can use WASI 0.1). Some languages have first-party support, while others rely on externally maintained tools.

LanguageNameOutputWASI VersionMaintained ByNotes
C and C++wasi-sdkModules; components via wasm-tools component new0.1, 0.2W3C Wasm CG0.3 toolchain support is not yet shipped
C#componentize-dotnetComponents0.2Bytecode AlliancePre-release toolchain
GoUpstream Go (GOOS=wasip1)Modules0.1Go Project
Gogo-modules; TinyGoComponents0.2Bytecode Alliance; TinyGo Project
JavaGraalVMPlannedPlannedOraclePlanned: see the tracking issue, roadmap, and presentation
JavaScript and TypeScriptjcoComponents0.2; 0.3 in progressBytecode AllianceThe preview3-shim package ships P3 host bindings; streams support landed, futures support following
KotlinKotlinModules0.2JetBrainsImplementation in progress; see the tracking issue
MoonBitMoonBit compiler with wit-bindgen MoonBit backendModules; components via wasm-tools component new0.2MoonBit
Pythoncomponentize-pyComponents0.2Bytecode Alliance
PythoncpythonModules0.2PythonImplementation in progress
Rubyruby.wasmModules0.2RubyImplementation in progress
Rustwasm32-wasip2 and wasm32-wasip3 compiler targetsModules and components0.1, 0.2; 0.3 nightlyRust Projectwasm32-wasip2 is Tier 2 on stable; wasm32-wasip3 is Tier 3, nightly only. See the 0.2 introduction and 0.2 stabilization
SwiftSwiftPlannedPlannedSwiftPlanned: see the accepted roadmap vision
Zigzig build-exe -target wasm32-wasiModules0.1ZigNo first-party Zig component toolchain

Notes

  • Modules vs components. A Wasm module is a single binary in the core WebAssembly format and can use WASI 0.1. A component is built to the Component Model and can use WASI 0.2 or 0.3, gaining composability, cross-language interoperability, and richer interface types. See the Interfaces and Roadmap pages for more on the WASI releases.
  • Adapting modules to components. Several toolchains produce core modules today and wrap them into components using wasm-tools component new with a P1-to-P2 adapter. This is the path for C/C++ and MoonBit.
  • WASI 0.3 ecosystem state. Broad language-level P3 support is still landing. The Rust wasm32-wasip3 target is Tier 3 (nightly only). jco ships a preview3-shim package with streams support landed and futures support following. Other toolchains have not yet shipped P3 support.
  • Snapshot pinning. When working with WASI 0.3, all WIT-aware tools must target the same snapshot (currently 0.3.0-rc-2026-03-15). Mismatches surface as confusing wrong type errors at instantiation.

Building guides

For hands-on guides covering setup and a "hello world" per language, see the Component Model documentation:

Bindings generators

The bindings generators below provide a way to make Wasm function calls using interfaces in a given language.

FromToName
Wasm Interface TypesCwit-bindgen c
Wasm Interface TypesC++wit-bindgen cpp
Wasm Interface TypesC#wit-bindgen csharp
Wasm Interface TypesJSON Schemacomponent2json
Wasm Interface TypesMarkdownwit-bindgen markdown
Wasm Interface TypesMoonbitwit-bindgen moonbit
Wasm Interface TypesRustwit-bindgen rust
WebIDLWasm Interface Typeswebidl2wit