Skip to content
Example of the C API to embed the Wasmer runtime
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.

C-API Embedder App Example

This repo showcases how to use the wasmer-runtime-c-api from C, based on the blogpost:

See wasmer-c-api-example.c for the example implementation.

The wasm-sample-app directory contains an example C wasm app to run in the embedder app.


  • CMake
  • Emscripten to build the sample app

Building & Running

# Building the wasm-sample-app
cd wasm-sample-app && emcc source.c  -Os -s SIDE_MODULE=1 -s EXPORTED_FUNCTIONS="['_hello_wasm']" -o target.wasm

# Build the embedder api
cmake .

# Run the executable
You can’t perform that action at this time.