Skip to main content
Browser SDK / Browser vs Node Moss ships two JavaScript clients. They share a similar API surface but target different environments. Pick the one that matches where your code runs.

Which one do I use?

  • Use @moss-dev/moss-web for client-side, in-browser search. Queries run locally on WebAssembly, so once an index is loaded there are no server round-trips and no data leaves the device.
  • Use @moss-dev/moss for server-side (Node.js) workloads, such as API routes, backend services, and pipelines.

Differences

Both clients require an index to be loaded before querying. In the browser SDK, call loadIndex before query.