Panel setup for SMProxy¶
Providers can serve plain server links with metadata, a Base64-encoded list, or complete Xray JSON configurations. JSON is not required for subscription names, usage, expiry, support or appearance. Use it when a connection needs full-config settings that cannot be represented by a share link or supported metadata.
Checked against panel source code on 19 November 2026. UI labels and available options vary by version and fork; setting keys below help identify the actual controls. A protocol supported by SMProxy is not necessarily emitted by every panel format.
What to send¶
A good starting point is the original subscription URL, a server-link list, and standard response headers:
Profile-Title: base64:U01Qcm94eSBkZW1v
Subscription-Userinfo: upload=0; download=1048576; total=0; expire=0
Profile-Update-Interval: 12
Support-Url: https://provider.example.com/support
Profile-Web-Page-Url: https://provider.example.com/account
total=0 means unlimited; expire=0 means no expiry. A nonzero expiry is Unix time in seconds. Traffic values are bytes and the refresh interval is hours, not minutes.
Supported metadata can instead be included in a text-list body:
#profile-title: base64:U01Qcm94eSBkZW1v
#subscription-userinfo: upload=0; download=1048576; total=0; expire=0
#profile-update-interval: 12
#support-url: https://provider.example.com/support
vless://00000000-0000-0000-0000-000000000000@vpn.example.com:443?security=tls&sni=vpn.example.com&type=tcp#Demo
This illustrates the format, not a working server. Base64-encode the whole text including metadata. Do not insert comments into JSON. An actual HTTP header takes precedence over the same body key. Only supported keys are read.
Optional per-subscription appearance:
#s-providerid: YOUR_PROVIDER_ID
#s-fonts: {"text":80,"subscription-name":85,"server-name":80,"protocol":70}
#s-layout: {"density":"compact","card-padding-x":8,"info-gap":2,"server-gap":0}
The Provider ID must belong to an active provider account. Without it, s-fonts and s-layout are ignored. They affect only this subscription. See appearance and Provider ID requirements. Use the same names without # in HTTP headers.
When the panel has no field for a header¶
Use built-in settings for standard metadata. SMProxy-specific keys such as s-fonts and s-layout must be supplied explicitly through supported custom response headers, a text subscription template, or your own handler/reverse proxy on the subscription route only. Otherwise a panel change is needed. Putting metadata in a server name does not make it a response header.
For Base64, assemble the links and comments first, then encode the result. For JSON, use HTTP response headers. Enabling JSON does not automatically add appearance settings or a Provider ID.
Identifying SMProxy¶
SMProxy sends its own User-Agent, shaped as SMProxy/<version>/<build>-<platform>. Match (?i)^SMProxy/ rather than a specific build or Android only.
Do not impersonate Happ, INCY, Clash or v2rayNG: panels may return different settings and node sets. Accept: application/json is not a universal request for Xray configuration; JSON may also be sing-box configuration or account status.
Why not append Happ-compatible to the User-Agent¶
Panels recognize Happ differently: the checked 3x-ui matches the standalone word happ anywhere in the string, while Remnawave and Marzban expect a Happ/ prefix. Appending Happ-compatible after SMProxy/... is therefore not capability negotiation. It enables Happ settings on one panel and does nothing on another. Support for individual headers does not guarantee support for another client's encrypted payloads, commands or every setting. Keep SMProxy's own identity and add a panel-side SMProxy rule.
3x-ui¶
Open Settings → Subscription → Formats (labels vary by version).
- Text/Base64: enable subscriptions (
subEnable).subEncrypt=trueBase64-encodes the list; it is not encryption. Share the actualsubPathURL. SetsubTitle,subSupportUrl, profile-page settings andsubUpdates(hours). - Separate JSON URL: enable
subJsonEnableand share the panel-generated URL usingsubJsonPath. - JSON on the ordinary URL for SMProxy: additionally enable
subJsonAutoDetectand setsubJsonUserAgentRegex=(?i)^SMProxy/. Ensure an earlier Clash matcher does not intercept it.
The checked version omits TUIC and AmneziaWG from JSON output. Prefer text/Base64 for mixed subscriptions and compare all nodes before switching. Some Happ/INCY descriptions and special settings are UA-gated; they do not automatically reach SMProxy. Do not append html=1 or view=html to an application subscription URL.
Remnawave¶
In Subscription → Response Rules, add an enabled rule above a general matching rule:
- Header:
User-Agent; operator: starts with (STARTS_WITH); value:SMProxy/; case sensitivity: off. Alternatively useREGEXwith^SMProxy/and case sensitivity off; do not use the inline(?i)flag in JavaScript regex. - Response: XRAY_BASE64 for server links or XRAY_JSON for full configuration.
- Set profile metadata in subscription/profile settings and supported custom response headers.
Rules can inspect other request headers too. The known-client fallback for JSON at the base URL does not include SMProxy: use an explicit rule. A /json suffix works only when the administrator permits format selection by path. Node availability can depend on output format and client capabilities; compare the complete list.
Marzban¶
The ordinary URL returns Base64 links for an unrecognized User-Agent. Set SUB_PROFILE_TITLE, SUB_SUPPORT_URL and SUB_UPDATE_INTERVAL; metadata is delivered as HTTP headers.
Use .../<token>/v2ray-json for explicit JSON or .../<token>/v2ray for Base64, preserving the panel URL prefix and token. USE_CUSTOM_JSON_DEFAULT and USE_CUSTOM_JSON_FOR_* still rely on known-client detection; enabling them does not register SMProxy. Returning JSON to SMProxy at the base URL requires a panel/fork change. Do not change the client's identity to work around this.
PasarGuard¶
In subscription settings, add a client rule before a general or blocking rule:
links selects plain text, links_base64 selects Base64 and xray selects Xray JSON. This is one rule, not a complete settings file. Enable the corresponding format. The checked version returns 406 Client not supported when no rule matches.
Set title, support, interval and other subscription metadata in subscription settings. Rule-level response_headers can add values. Placement header / body_start / body_end sends metadata as HTTP headers or #key: value comments at the beginning/end of text or Base64 output. For JSON, use HTTP headers rather than comments. SMProxy Provider ID requirements still apply.
Hiddify¶
Use URLs generated by the user's subscription page:
/sub: plain server links;/sub64: Base64 server links;/xray: Xray JSON;/auto: UA/settings-based selection with a link-list fallback.
These are suffixes within the private user URL, not paths to append at the domain root. Preserve the secret prefix and user ID. Configure title/branding and support in profile/branding settings. Shared response headers contain title, usage, quota, expiry and interval. Do not assume /auto selects JSON for SMProxy; use the explicit Xray URL when required, then compare all nodes.
Verify before distributing¶
- Import and refresh in current SMProxy: check title, usage/unlimited status, expiry, support and node count.
- Test plain text and Base64, including body metadata. JSON MIME type alone proves nothing: the body must be compatible Xray configuration, not sing-box or account status.
- Check every protocol/transport you distribute, especially AmneziaWG, TUIC, Hysteria 2 and AnyTLS. Do not switch to a format that loses nodes.
- Verify refresh uses the same URL. An HTTP error, empty body or HTML page is not a valid replacement subscription.
- Keep real subscription tokens, configurations and passwords out of public reports. Share sanitized headers and response structure for diagnostics.
Link formats · Metadata and appearance · Request headers · Routing