webui

Nim wrapper for WebUI

Wrapper score 15/100 · tests present · no docs generated

Wraps a native library — check OS Compatibility below for platform-specific linking notes.

Summary

Latest Version Unknown
License MIT
CI Status Failing
Downloads 0
Last Indexed 2026-07-21 05:23

Installation

nimble install webui
choosenim install webui
git clone https://github.com/webui-dev/nim-webui

OS Compatibility

Platform Linux macOS Windows FreeBSD OpenBSD NetBSD Android iOS WASM Embedded
webui - - - - - - -

Source

Repository https://github.com/webui-dev/nim-webui
Homepage https://webui.me/
Registry Source nimble_official

README

![Logo](https://raw.githubusercontent.com/webui-dev/webui-logo/main/webui_nim.png) # Nim-WebUI [last-commit]: https://img.shields.io/github/last-commit/webui-dev/nim-webui?style=for-the-badge&logo=github&logoColor=C0CAF5&labelColor=414868 [release-version]: https://img.shields.io/github/v/tag/webui-dev/nim-webui?style=for-the-badge&logo=webtrees&logoColor=C0CAF5&labelColor=414868&color=7664C6 [license]: https://img.shields.io/github/license/webui-dev/nim-webui?style=for-the-badge&logo=opensourcehardware&label=License&logoColor=C0CAF5&labelColor=414868&color=8c73cc [![][last-commit]](https://github.com/webui-dev/nim-webui/pulse) [![][release-version]](https://github.com/webui-dev/nim-webui/releases/latest) [![][license]](https://github.com/webui-dev/nim-webui/blob/main/LICENSE) > Use any web browser or WebView as GUI, with Nim in the backend and modern web technologies in the frontend, all in a lightweight portable lib. ![Screenshot](https://raw.githubusercontent.com/webui-dev/webui-logo/main/screenshot.png)

Features

  • Fully Independent (Only needs a web browser or a WebView at runtime)
  • Lightweight & Small memory footprint
  • Fast binary communication protocol between WebUI and the browser
  • Multi-platform & Multi-Browser
  • Using private profile for safety
  • Cross-platform WebView

Installation

Install via Nimble:

nimble install webui

Documentation

Online documentation can be found here: - https://webui.me/docs/2.4.0/#/nim_api - https://yesdrx.github.io/nim-webui// (docs in Nim format)

I suggest to get started using some examples or WebUI's own examples or documentation.

Heres a very minimal example of using the wrapper:

import webui

let window = newWindow() # Create a new Window
window.show("<html>Hello</html>") # Show the window with html content

wait() # Wait until the window gets closed

Examples

Examples can be found here at examples/.

If you're trying to run the examples remember to clone the repository recursively, as it depends on the WebUI repo as a submodule. Here's the command to do so for the truly lazy:

git clone --recursive https://github.com/webui-dev/nim-webui.git

Bindings and Wrapper

The Nim library exposes two files: webui.nim and webui/bindings.nim. webui/bindings.nim are low-level bindings for WebUI, generated by c2nim using script generate_bindings.nims. webui.nim is a high-level wrapper for WebUI, using native Nim types and avoiding pointers.

The wrapper and bindings also allow to to control whether or not to statically compile WebUI's C sources into your application, compile with a static library, or to depend on a DLL. Static compilation is the default behavior.

To compile with a static library, pass -d:useWebviewStaticLib or -d:useWebviewStaticLibrary to the Nim compiler. To depend on a DLL, pass -d:useWebviewDll instead. If neither of these flags are passed to the Nim compiler, static compilation will take place instead. Static libraries and DLLs can be found in WebUI's website here.

In addition, you can also enable WebUI's logging via -d:webuiLog but that flag only works for static compilation.

Other Wrappers/Bindings

Language Status Link
Go ✔️ Go-WebUI
Nim ✔️ Nim-WebUI
Pascal ✔️ Pascal-WebUI
Python ✔️ Python-WebUI
Rust ✔️ Rust-WebUI
TypeScript / JavaScript ✔️ Deno-WebUI
V ✔️ V-WebUI
Zig ✔️ Zig-WebUI
Odin not complete Odin-WebUI
Delphi ✔️ WebUI4Delphi
QuickJS ✔️ QuickUI

Supported Web Browsers

Browser Windows macOS Linux
Mozilla Firefox ✔️ ✔️ ✔️
Google Chrome ✔️ ✔️ ✔️
Microsoft Edge ✔️ ✔️ ✔️
Chromium ✔️ ✔️ ✔️
Yandex ✔️ ✔️ ✔️
Brave ✔️ ✔️ ✔️
Vivaldi ✔️ ✔️ ✔️
Epic ✔️ ✔️ not available
Apple Safari not available coming soon not available
Opera coming soon coming soon coming soon

Supported WebView Platforms

WebView Status
Windows WebView2 ✔️
Linux GTK WebView ✔️
macOS WKWebView ✔️

License

MIT License. See LICENSE

Original WebUI library is licensed under MIT. See LICENSE.