# S-UI Wiki: Your Friendly Guide to the Sing-Box Panel > S-UI is a web-based management panel built on top of SagerNet/Sing-Box, a universal proxy platform. It gives you a browser dashboard to configure proxies, manage clients, track traffic, and generate subscription links — all without touching config files by hand. This is a Grok-Wiki source-grounded repository wiki. Use the complete Markdown link when an agent needs the full repo context. ## Context Links - [Complete Markdown wiki](https://grok-wiki.com/public/wiki/alireza0-s-ui-2ddf594ac444/llms-full.txt) - [Complete Markdown alias](https://grok-wiki.com/public/wiki/alireza0-s-ui-2ddf594ac444.md) - [Human interactive wiki](https://grok-wiki.com/public/wiki/alireza0-s-ui-2ddf594ac444) - [GitHub repository](https://github.com/alireza0/s-ui) ## Repository - Repository: alireza0/s-ui - Generated: 2026-05-22T01:22:59.804Z - Updated: 2026-05-22T01:36:27.952Z - Runtime: Claude Code - Format: Custom - Pages: 6 ## Pages - [Welcome! So What Is S-UI?](https://grok-wiki.com/public/wiki/alireza0-s-ui-2ddf594ac444/pages/01-welcome-so-what-is-s-ui.md): Imagine sing-box is a powerful but silent robot that routes internet traffic. S-UI is the friendly remote control you use to tell that robot what to do — through a web browser, not a command line. This opening page asks "why does this exist?" and maps out every other page in the wiki so you always know where to look next. - [How Do All the Pieces Fit Together?](https://grok-wiki.com/public/wiki/alireza0-s-ui-2ddf594ac444/pages/02-how-do-all-the-pieces-fit-together.md): If S-UI were a pizza restaurant, what would the kitchen, the waiter, and the cash register each do? This page walks through the major Go packages — cmd, core, api, web, sub, database, cronjob — and asks "what question does each one answer?" so you build a mental map before diving into details. - [The Robot Inside: How Sing-Box Starts and Stops](https://grok-wiki.com/public/wiki/alireza0-s-ui-2ddf594ac444/pages/03-the-robot-inside-how-sing-box-starts-and-stops.md): When you press "Start" in the dashboard, what actually happens under the hood? This page follows a single button-click all the way down to the sing-box instance, asking at each step: "who tells whom, and how?" Covers core/main.go, box.go, register*.go, and the outbound-check safety net. - [The Memory and the Alarm Clock: Database & Cron Jobs](https://grok-wiki.com/public/wiki/alireza0-s-ui-2ddf594ac444/pages/04-the-memory-and-the-alarm-clock-database-cron-jobs.md): Where does S-UI remember your settings when you restart the server? And who cleans up old traffic stats at 3 a.m.? This page explores the SQLite/GORM database layer and the five scheduled jobs (stats, depletion check, WAL checkpoint, core health check, stats deletion), asking "what problem would happen if this job didn't exist?" - [The Waiter: How Your Browser Commands Reach the Engine](https://grok-wiki.com/public/wiki/alireza0-s-ui-2ddf594ac444/pages/05-the-waiter-how-your-browser-commands-reach-the-engine.md): When you click a button in the web panel, a request travels from your browser to a Gin HTTP handler to a service function. This page traces that journey, explaining the v2 token-based API, the admin command handlers, and the domain-validation middleware — asking "what could go wrong at each door, and how is it guarded?" - [The Gift Bag: How Subscription Links Are Built](https://grok-wiki.com/public/wiki/alireza0-s-ui-2ddf594ac444/pages/06-the-gift-bag-how-subscription-links-are-built.md): A subscription link is a URL your VPN app fetches to learn which servers to use. This closing page asks: "how does S-UI turn raw database records into a Clash YAML, a JSON config, or a base64 share-link?" It walks through sub/subService.go, clashService.go, jsonService.go, and linkService.go — then leaves you with the key question to keep exploring: what new formats could you add, and where would you start? ## Source Files - `api/apiService.go` - `api/apiV2Handler.go` - `app/app.go` - `cmd/admin.go` - `cmd/cmd.go` - `cmd/setting.go` - `config/config.go` - `core/box.go` - `core/endpoint.go` - `core/log.go` - `core/main.go` - `core/outbound_check.go` - `core/register.go` - `core/tracker_conn.go` - `core/tracker_stats.go` - `cronjob/checkCoreJob.go` - `cronjob/cronJob.go` - `cronjob/delStatsJob.go` - `cronjob/depleteJob.go` - `cronjob/statsJob.go` - `cronjob/WALCheckpointJob.go` - `database/backup.go` - `database/db.go` - `Dockerfile` - `go.mod` - `install.sh` - `middleware/domainValidator.go` - `README.md` - `s-ui.service` - `sub/clashService.go` - `sub/jsonService.go` - `sub/linkService.go` - `sub/sub.go` - `sub/subHandler.go` - `sub/subService.go` - `util/genLink.go` - `util/outJson.go` - `util/subInfo.go` - `web/web.go`