Snell nodes and version behavior
The client uses a pre-shared key psk to establish the Snell outbound and selects the corresponding packet format based on version . The server address, port, PSK, and version must all come from the same node configuration.
The version directly determines UDP and connection multiplexing support. If version is omitted, the current implementation defaults to v1 for compatibility with older configurations, so the version field should not be treated as optional display-only information.
Minimum required fields
The minimum Snell configuration consists of four common connection fields and one PSK. Specify the version explicitly to avoid falling back to the default v1.
nameRequired- The node name used by policy groups and rules.
typeRequired- Set this to
snell。 serverRequired- The Snell server domain name or IP address.
portRequired- The Snell server listening port.
pskRequired- The Snell pre-shared key. It must exactly match the server.
versionExplicitly specify- Supports 1, 2, 3, 4, and 5; if omitted, the current implementation defaults to 1.
Version, UDP, and connection multiplexing
The current field reference limits UDP and reuse availability by Snell version. The current implementation uses the v5 server's backward compatibility with v4 clients and handles a v5 configuration through the v4 client path.
| version | UDP | reuse configuration | Description |
|---|---|---|---|
| 1 | Not supported | Not applicable | Current default when version is omitted |
| 2 | Not supported | Always multiplexed | v2 always uses connection multiplexing; thereuse switch has no effect |
| 3 | Supported | Not applicable | Can be enabled udp: true |
| 4 | Supported | Supported | reuse Defaults to false; enable it only if the server supports it |
| 5 | Supported | Supported | The current implementation uses v4 client compatibility for v5 servers |
udpVersion-dependent- Can be enabled only with v3, v4, or v5; enabling it with v1 or v2 causes initialization to fail.
reuseVersion-dependent- The official option controls connection multiplexing for v4 and v5 and defaults to
false。
Obfuscation modes and mode-specific fields
obfs-opts configures Snell's outer obfuscation layer. Each mode uses a different field set, so include only the mode and parameters actually enabled on the server.
| mode | Primary fields | Constraints |
|---|---|---|
http | host | HTTP-like obfuscation; host must match the server configuration |
tls | host | simple-obfs TLS-like traffic; this is not a standard HTTPS proxy |
shadow-tls | host、password、version、alpn | Shadow TLS supports versions 1, 2, and 3 |
restls | host、password、version-hint、restls-script | version-hint may be tls12 or tls13 |
jls | host、username、password、alpn | The authentication fields must match the JLS server. |
obfs-optsOptional- The Snell obfuscation configuration object. It can be omitted when obfuscation is not used.
client-fingerprintOptional- Used for TLS-like modes such as Shadow TLS, Restls, or JLS. The official default is Chrome.
obfs-opts.hostOptional- The domain name presented by the obfuscation layer. Use the value supplied by the server.
obfs-opts.passwordMode-dependent- The outer password for Shadow TLS or Restls mode; it is not the same as Snell
psk。
Snell v4 obfuscation example and troubleshooting
This example explicitly selects v4 and enables UDP. It uses simple-obfs TLS-like traffic; if the server does not enable obfuscation, remove the entire obfs-opts。
- If authentication fails, first verify
psk; do not enter the outer Shadow TLS or Restls password inpsk。 - If TCP works but UDP initialization fails, check whether
versionis 3, 4, or 5. - If the obfuscation handshake fails, verify mode, host, the outer password, version, and client fingerprint one by one.
proxies:
- name: snell-node
type: snell
server: server.example.com
port: 44046
psk: your-psk
version: 4
udp: true
obfs-opts:
mode: tls
host: example.com