Rule Syntax
Match fields for custom rules: domain, domain_suffix, geosite, geoip, process_name, ip_cidr, port, final.
Custom rules live under Rules → Custom, one per line. Each rule = match condition + target classifier. Fields align with sing-box route rules.
Match fields#
| Field | Matches | Example |
|---|---|---|
domain | Exact domain | openai.com |
domain_suffix | Domain + subdomains | google.com hits *.google.com |
domain_keyword | Keyword inside domain | netflix |
geosite | GEOSITE category | geosite:category-ads-all |
geoip | IP origin | geoip:cn |
ip_cidr | IP range | 91.108.56.0/22 |
process_name | Process name | steam.exe |
port | Destination port | 22 |
network | Protocol | udp, tcp |
Examples#
Pin the company intranet to direct:
domain_suffix=corp.example.com→ classifier "Direct"
Send one game's process through the fast pool:
process_name=game.exe→ classifier "Gaming"
Fallback#
- final: where traffic goes when nothing matched — set in the routing profile, usually "default Route" or "default Direct".
No raw JSON needed
UI rules compile into the sing-box core config — you fill fields, AirLane guarantees the syntax. Raw config editing lives under Settings → Routing profiles.Was this doc helpful?Still stuck? Ask on GitHub