WebAssembly Fundamentals / Chapter 1 — How It Works (lessons 1–5) / Lesson 1
What Is WebAssembly?
Time needed: about 5 min (estimate)
Reading settings
These settings are remembered on this device only.
You can try the opening of this lesson without an account.
Machine code that runs in the browser
WebAssembly (wasm for short) is a compact, fast machine-code format for running in browsers. Compile a program written in C, C++, Rust, Go, and so on to wasm, and it runs in the browser alongside JavaScript. It doesn't replace JavaScript; it's JavaScript's partner for heavy computation and for bringing in programs written in other languages.
In fact, this site uses it. The editor in the Python courses runs on Pyodide, which is the Python runtime itself (CPython) compiled to wasm. The SQL editor is sql.js, SQLite compiled to wasm. Python and SQLite run inside your browser without anything being sent to a server.
Where WebAssembly is used
Tab indents. To leave the editor, press Esc, then Tab.
Create a free account to keep reading
With an account you can read the rest of this lesson, take the quiz, and read every free lesson in this course. Lessons you answer correctly are recorded as complete.
Report a problem with this lesson
Log in to send a report.