PHPackages                             kingbes/webui - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. kingbes/webui

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

kingbes/webui
=============

webui 绑定 php 实现跨平台桌面应用

v0.0.7(12mo ago)23871MITCPHP &gt;=8.1.0

Since Aug 9Pushed 12mo ago1 watchersCompare

[ Source](https://github.com/KingBes/php-webui-composer)[ Packagist](https://packagist.org/packages/kingbes/webui)[ RSS](/packages/kingbes-webui/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (7)Dependencies (1)Versions (8)Used By (0)

[![Logo](https://raw.githubusercontent.com/webui-dev/webui-logo/14fd595844f57ce751dfc751297b1468b10de77a/webui_120.svg)](https://raw.githubusercontent.com/webui-dev/webui-logo/14fd595844f57ce751dfc751297b1468b10de77a/webui_120.svg)

WebUI for PHP
=============

[](#webui-for-php)

[![](https://camo.githubusercontent.com/1075e4553110c0a8fd070c567ea2b9cd8a1eb716bf2baeb124f07378b54ed2e7/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f77656275692d6465762f77656275692f63692e796d6c3f6272616e63683d6d61696e267374796c653d666f722d7468652d6261646765266c6f676f3d676974687562616374696f6e73266c6162656c436f6c6f723d343134383638266c6f676f436f6c6f723d433043414635)](https://github.com/webui-dev/webui/actions?query=branch%3Amain)[![](https://camo.githubusercontent.com/8c66a9e4445ff43b8a11c82c66fe6ac54424f6354e5d8bbc7acff452b6fccadb/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6173742d636f6d6d69742f77656275692d6465762f77656275693f7374796c653d666f722d7468652d6261646765266c6f676f3d676974687562266c6f676f436f6c6f723d433043414635266c6162656c436f6c6f723d343134383638)](https://github.com/webui-dev/webui/pulse)[![](https://camo.githubusercontent.com/f33c495d3dc7d8ba476b5b8b186de93c98e51d725ffe89902b2660fd806e0432/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f762f7461672f77656275692d6465762f77656275693f7374796c653d666f722d7468652d6261646765266c6f676f3d7765627472656573266c6f676f436f6c6f723d433043414635266c6162656c436f6c6f723d34313438363826636f6c6f723d373636344336)](https://github.com/webui-dev/webui/releases/latest)[![](https://camo.githubusercontent.com/4e4fdecfe0b56dafe9c37ffface4eebeeea05d976e238890a1e893cd5f4a6cb8/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f77656275692d6465762f77656275693f7374796c653d666f722d7468652d6261646765266c6f676f3d6f70656e736f757263656861726477617265266c6162656c3d4c6963656e7365266c6f676f436f6c6f723d433043414635266c6162656c436f6c6f723d34313438363826636f6c6f723d386337336363)](https://github.com/webui-dev/webui/blob/main/LICENSE)

> Use any web browser or WebView as GUI, with your preferred language in the backend and modern web technologies in the frontend, all in a lightweight portable library.

[![Screenshot](https://raw.githubusercontent.com/webui-dev/webui-logo/main/screenshot.png)](https://raw.githubusercontent.com/webui-dev/webui-logo/main/screenshot.png)

[中文自述](/README-zh-CN.md)

composer
========

[](#composer)

```
composer require kingbes/webui
```

requirePHP8.1+FFI\*Windows-x64trueLinux-x64trueLinux-armTo be testedLinux-arm64To be testedMacOs-x64To be testedMacOs-arm64To be testedexample
=======

[](#example)

1. Example I

index.html

```
>

    Document

    asd

        function btn() {
            hello('hello').then(function (res) {
                console.log(res)
            })
        }

```

index.php

```
require "./vendor/autoload.php";

use Kingbes\Webui;
use Kingbes\JavaScript;

$Webui = new Webui;
$html = file_get_contents(__DIR__ . DIRECTORY_SEPARATOR . "index.html");
$window = $Webui->newWindow();
$bind = $Webui->bind($window, "hello", function ($event, JavaScript $js) {
    // Gets the first argument as a string
    $arg_one = $js->getString($event);
    var_dump($arg_one);

    // return string
    $js->returnString($event, "nihao");
});
$Webui->show($window, $html);
$Webui->wait();
$Webui->clean();
```

Various usage instructions
--------------------------

[](#various-usage-instructions)

1. `Webui` Webui class
2. `JavaScript` Used to interact with js bindings
3. `Wrapper` Wrappers that wrap the entire interaction, etc
4. `Cobj` Wrappers, which wrap the entire interaction with other C object classes, some functions may be required

MORE
====

[](#more)

[website](https://webui.me/)

###  Health Score

32

—

LowBetter than 72% of packages

Maintenance50

Moderate activity, may be stable

Popularity18

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity43

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~47 days

Recently: every ~68 days

Total

7

Last Release

360d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/fb58545c720c65fc3a128dec9077ca1e63c7de006c8ffa6f2041636ad94d1d74?d=identicon)[KingBes](/maintainers/KingBes)

---

Top Contributors

[![KingBes](https://avatars.githubusercontent.com/u/48203677?v=4)](https://github.com/KingBes "KingBes (19 commits)")

---

Tags

phpwebuiphpcomposerdesktopffiWebUI

### Embed Badge

![Health badge](/badges/kingbes-webui/health.svg)

```
[![Health](https://phpackages.com/badges/kingbes-webui/health.svg)](https://phpackages.com/packages/kingbes-webui)
```

###  Alternatives

[jbzoo/composer-diff

See what has changed after a composer update.

53888.9k1](/packages/jbzoo-composer-diff)[liborm85/composer-vendor-cleaner

Composer Vendor Cleaner removes unnecessary development files and directories from vendor directory.

35342.7k1](/packages/liborm85-composer-vendor-cleaner)[camcima/php-geohash

Refactored GeoHash package

1074.0k](/packages/camcima-php-geohash)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
