Official Manual / Configuration and Rules

Shadowrocket Rules and Configuration Guide

From configuration structure to the first matching rule: syntax, policies, resolution behavior, and validation.

Use this page as a reference; it does not replace the initial connection setup. If you haven't imported server details yet, follow the quick-start guide to import a subscription with Subscribe, select a server, and verify the connection. Then return here to adjust routing. The tutorial gets the connection working; this page explains how the configuration works and how to tell whether a change has taken effect.

The instructions below assume you already have your own subscription or server details. Get subscription links from your service provider. This site does not provide, sell, or recommend servers or subscriptions. A one-time app purchase does not include a network service plan: app access and network service are separate costs.

There are two ways to get Shadowrocket: the iPhone / iPad version is a one-time $2.99 purchase on the App Store; check the App Store listing for system requirements. The Mac (Apple silicon and Intel), Windows, Android, and Linux versions are free. See the download page for each platform. Installers for desktop and Android platforms are available from this site under /dl/.

01 Configuration Structure and Scope of Changes

A Shadowrocket configuration describes how the client should handle connections; it is not a list of server credentials. Content imported through Subscribe typically manages server entries, while the file selected in Config controls rules and related settings. They can be updated separately. If a subscription update succeeds but traffic is routed the same way, check the active configuration before importing the subscription again. Server details determine where you can connect; rules determine which policy applies to each request.

Configuration sections

Sections are marked with square-bracketed headers, such as [General] and [Rule]. General settings commonly use key-value pairs, while Rule usually contains one rule per line, with fields separated by English commas. A section header is not an ordinary comment; omitting one can put later entries in the wrong section. Chinese commas, full-width equals signs, and special spaces copied from rich text can make an apparently correct line parse incorrectly.

[General]
bypass-system = true
dns-server = system

[Rule]
DOMAIN-SUFFIX,example.com,PROXY
IP-CIDR,192.168.0.0/16,DIRECT,no-resolve
FINAL,PROXY

This is a structural example, not a complete configuration for every network. bypass-system affects system traffic bypass behavior, and dns-server = system means to use the system-provided resolver. Neither supplies server details or guarantees that every connection will be handled by Rule. When reading a configuration, first identify the entry point and bypass conditions, then review the rule list. Don't focus only on the final policy lines.

What the four common sections do

SectionMain purposeWhat to check
[General]General network and DNS settingsDNS source and whether bypass conditions fit the current network
[Rule]Match requests and select a policyRule order, target fields, and FINAL
[Host]Provide local DNS mappings for specified hostnamesWhether the address is still valid and overrides normal resolution
[URL Rewrite]Apply rewrites or redirects using URL expressionsExpression scope, destination URL, and visibility conditions

If you don't use a feature, there's no need to add its section just to make the configuration look complete. Be especially cautious about copying Host mappings or rewrite rules from unknown sources: one outdated mapping can bypass normal resolution, and an overly broad rewrite can affect sign-in or redirects. A shorter configuration isn't automatically better, but you should be able to explain the purpose, scope, and rollback method for every entry.

Editing, saving, and enabling are separate steps

In Config, find the configuration that's actually in use. Save a copy first, give it a name that clearly distinguishes its purpose, and then edit it. After saving, check for errors, return to the configuration list, and confirm the selected file. Editing an inactive copy won't change current routing. Selecting another remote configuration won't automatically merge your local changes. For settings that require reconnecting, disconnect and reconnect, then test with a new request.

Remote configurations can also overwrite changes when refreshed. If you edit a file that gets replaced during an update, your custom rules may be lost next time. First check how that file is updated, then decide whether to use a separate local copy or a supported method for preserving changes. Avoid maintaining several active candidate files with similar names but different contents. When troubleshooting, record the file name, selected status, and changes made; that's more reliable than trying to remember which file you last edited.

Settings and navigation may differ between platforms and builds. This page explains configuration semantics, not every screen pixel. If the current client doesn't recognize a field, remove it and check the in-app guidance rather than adding parameters one after another to clear the error. For a first-time setup, return to the configuration and validation steps in the tutorial. You can also search the FAQ by symptom.

02 Matching Order, Overrides, and FINAL

The key principle of rule-based routing is this: when a request enters rule processing, Rule is typically checked from top to bottom, and the first matching rule determines the policy. The client doesn't collect all matches and then choose the one that seems most specific. Both the rule text and its position matter. Put a specific exception below a broad rule, and it may as well not be there.

Put exceptions before broader rules

[Rule]
DOMAIN,login.example.com,DIRECT
DOMAIN-SUFFIX,example.com,PROXY
DOMAIN-KEYWORD,ads,REJECT
FINAL,PROXY

In this example, login.example.com matches the first line and uses DIRECT. Other domains under example.com can then match the second line. If you swap the first two lines, the login hostname matches the suffix rule first, and the later DOMAIN rule won't change its outcome. Don't assume DOMAIN automatically takes precedence over DOMAIN-SUFFIX; here, precedence comes from the order of the rules.

The third line shows another kind of override: if a subdomain of example.com also contains ads, the second line has already matched, so the later keyword rejection won't run. First decide what you want: should the entire domain family use PROXY, or should the ads keyword be rejected first? There's no universally correct order independent of your goal, but you should be able to explain which rule should handle every overlapping request.

FINAL is a fallback, not a forced override

FINAL,PROXY means use PROXY if no earlier rule determines the route. It has no domain condition and won't correct a malformed rule above it. If FINAL appears in the middle of the list, later rules won't get a chance to handle ordinary requests. In a typical configuration, put a single, clearly defined fallback at the end of Rule. Multiple FINAL entries can make the configuration harder to interpret.

[Rule]
DOMAIN-SUFFIX,example.com,PROXY
GEOIP,CN,DIRECT
FINAL,PROXY

This example checks the domain first, then the geographic classification of the destination address, and applies the fallback to anything left over. Even if a domain resolves to an address classified as CN by GEOIP, a matching suffix rule above it still routes the request through PROXY. Conversely, if the hostname isn't available, the domain rule may not match, so check the address rules that follow. Before interpreting a test result, confirm whether the available match information was a hostname or an address.

Rule order and bypass conditions are different things

“Top to bottom” describes what happens after a request enters this rule list. It doesn't mean the list overrides every system route, general bypass setting, or existing connection. If traffic was already bypassed by an earlier processing path, moving lines in Rule won't bring it back in. When troubleshooting local network access, distinguish General bypass settings, system routing, and DIRECT in Rule. They may look similar but apply at different stages.

Similarly, existing persistent connections may continue to use their original route after you change rules. Browser connection reuse, background app activity, and DNS caches can all mean that one refresh isn't enough to prove a new rule is failing. Create a new connection to the target; if needed, quit and reopen the app, then compare the destination hostname, matched rule, and policy in the logs. Judging priority only by whether a page loads can confuse server status with a rule issue.

Test rule priority with counterexamples

For every exception you add, prepare at least two test targets: one that should match the new rule and a similar one that should not. For example, after changing a rule for login.example.com, also test api.example.com. After adding an IP range, test an address outside that range. This helps catch both rules that don't take effect and rules with too broad a scope, giving you more useful evidence than one successful visit.

03 Domain, Address, and Request-Attribute Rules

Rule types determine which part of a request is compared. Domain rules look at the hostname, address rules at the destination IP, and USER-AGENT at an available request identifier. These are different kinds of information, not interchangeable ways to express the same thing. Before choosing a type, ask whether you need to match an exact hostname, a domain family, an IP range, or a recognizable request type. Then choose the syntax.

DOMAIN and DOMAIN-SUFFIX

DOMAIN,api.example.com,PROXY
DOMAIN-SUFFIX,example.net,DIRECT

Use DOMAIN for an exact hostname exception: it matches api.example.com but doesn't automatically include img.api.example.com. Use DOMAIN-SUFFIX for a domain suffix: example.net and its subdomains are in scope, but notexample.net is not a subdomain of example.net. Don't include a scheme, path, port, or trailing slash in the domain field; these aren't part of a domain match.

To distinguish a site's login, image, and API services, confirm the actual hostnames from real requests instead of assuming they all use the main site domain. Modern apps may use separate resource domains, and a single page may open multiple connections. A rule match for the main page only describes that connection; it doesn't mean every resource uses the same policy.

DOMAIN-KEYWORD has a broader scope

DOMAIN-KEYWORD,ads,REJECT

This rule illustrates matching a keyword in a domain; it isn't a general recommendation to block traffic. ads is just a string and may appear in domains that shouldn't be rejected. Keyword rules are usually harder to scope than suffix rules, so check for false positives before using them. If you know the exact hostname or a stable suffix, prefer a more precise rule type to reduce maintenance.

IP-CIDR, IP-CIDR6, and GEOIP

IP-CIDR,192.168.0.0/16,DIRECT,no-resolve
IP-CIDR6,fc00::/7,DIRECT,no-resolve
GEOIP,CN,DIRECT

IP-CIDR describes an IPv4 range using an address and prefix length; IP-CIDR6 handles IPv6. The prefix is not a port number or an optional note. A range that's too broad may include unrelated destination addresses. The private IPv4 and local IPv6 ranges in the examples are for illustration only. Whether traffic should connect directly also depends on system routing and the network you're on; don't assume every internal address is reachable.

no-resolve means not to actively resolve a hostname just for this address rule. If the request already has a destination IP, the rule can still compare it. This doesn't disable client DNS or make every domain request match a private address range. GEOIP relies on an address database classification; it doesn't indicate a site's language, place of registration, or the user's location. Database differences and changes in address assignments can affect the result.

USER-AGENT and the limits of visible information

USER-AGENT,ExampleApp*,DIRECT

USER-AGENT matches an available User-Agent identifier. ExampleApp in this example is a fictional test name, and the asterisk indicates an intended wildcard match. This isn't a rule for system app package names and can't guarantee identification of every encrypted request. If the request header isn't available at the connection stage, the rule has nothing reliable to compare against. An app with a name similar to the example won't necessarily have all its connections matched.

TypeWhat it matchesCommon mistake
DOMAINExact hostnameIncluding a full URL
DOMAIN-SUFFIXDomain and subdomainsTreating it as any character sequence ending in the suffix
DOMAIN-KEYWORDCharacter string in a domainUnderestimating the false-match scope
IP-CIDR / IP-CIDR6Destination IP rangeTreating an address range as a domain range
GEOIPDatabase classification of the destination addressInferring the result from the website's language
USER-AGENTAvailable request identifierAssuming it routes all traffic by app
FINALRequests not matched by earlier rulesPutting it in the middle of the list

When more than one type could express your intent, choose the one with the clearest meaning and fewest dependencies. Use DOMAIN for a hostname exception, DOMAIN-SUFFIX for a domain family, and CIDR for a defined internal address range. Use keywords only when broader coverage is genuinely needed; pair every broad rule with a counterexample that should not match, so mistakes don't get buried as the list grows.

04 PROXY, DIRECT, REJECT, and Global Routing

Rules answer “which requests match?” Policies answer “what happens after a match?” This page uses the three basic policy keywords PROXY, DIRECT, and REJECT, which should remain uppercase in the configuration. They're not the same as the interface labels Config, Proxy, and Direct: the former appear as rule actions, while the latter describe the Global Routing mode. Confusing these two layers is a common reason rules are written but not applied as expected.

What the three basic policies mean

PROXY sends matched connections through the proxy path. Check the selection in Home and the active configuration to see which server or related policy will be used. Writing PROXY doesn't mean you have a working server or guarantee that authentication, transport, and access to the destination will succeed. A rule can match correctly while the connection fails because the wrong server is selected, credentials have expired, or the destination is unreachable.

DIRECT connects to the destination without using the selected proxy server. It still depends on the local network, DNS, system routing, and the destination service. It doesn't “bypass every network problem.” For example, even with a DIRECT policy, a device can't connect to an internal admin page if it isn't on the relevant local network. When troubleshooting, verify “DIRECT is selected” and “DIRECT can reach the destination” separately.

REJECT denies a matched connection. The expected result is a failed request or an unloaded resource, not an automatic switch to another working path. An app may retry rejected requests repeatedly, generating more log entries; rejecting a required API may also disrupt the app. If this happens, identify the rejected destination first. Don't assume the server is down just because the main page won't load.

The three Global Routing modes

Interface labelWhat it meansWhat to check
ConfigConfig: route traffic according to the active configurationCheck Rule, priority, and the fallback
ProxyProxy: handle managed traffic in proxy modeTemporarily isolate differences caused by rules
DirectDirect: handle managed traffic in direct modeCompare access over the local network

Select Config when testing custom rules during normal use. Proxy can help check whether the proxy path itself works; Direct can help check whether the local network can reach the destination. Neither proves that a particular Rule is working. These modes also don't mean that all system traffic can be managed; system bypasses, app behavior, and existing connections still need to be considered separately.

[Rule]
DOMAIN,api.example.com,PROXY
DOMAIN,printer.example.net,DIRECT
DOMAIN,metrics.example.org,REJECT
FINAL,PROXY

Compare modes using the same destination

If a destination works in Proxy but fails in Config, check whether an earlier rule in Config matched DIRECT or REJECT before replacing the server. If it fails in both Proxy and Config, check the proxy path, DNS, and destination status. If Direct works but Proxy fails, investigate the selected server and its connection to the destination. Don't conclude from this alone that all your rules are wrong.

Keep the destination, network, and server selection as consistent as possible during comparisons, changing one condition at a time. Switching networks, modes, and servers together makes results hard to interpret. Also distinguish the initial page load from later resource requests: a webpage may generate PROXY, DIRECT, and REJECT entries at once, so no single entry represents the behavior of the whole page.

Protocol settings and routing policies handle different layers

Protocols such as Shadowsocks, VMess, VLESS, and Trojan determine how the proxy connection is established. Rule determines which requests use the proxy path. Changing DOMAIN-SUFFIX to DOMAIN won't fix an incorrect server password, and changing transport settings won't fix an overly broad rejection rule. For protocol fields, see the guide to protocols and common settings, then return here to check where requests are routed.

On Demand triggers connections based on conditions and should be understood separately from the routing mode selected in Global Routing. Connecting automatically doesn't mean Config is in use, and connecting manually doesn't mean rules are ignored. After switching modes, check the current connection status and selected configuration to avoid mistaking automatic connection behavior for a rule selection result.

05 How DNS, Host, and Address Rules Interact

Domain and address rules depend on different information, so DNS is often a key factor in troubleshooting routing. DNS resolves a hostname to an address; Rule then selects a policy based on the information available at that point. Caches, connection methods, and client settings can also affect processing. Don't assume that resolving to a particular address determines which route is used. Check the resolution path and the connection path separately.

Record the current state before changing the DNS source

[General]
dns-server = system

This line means to use the system resolver. It's a useful starting point for understanding the setting, not a universally optimal configuration. The current network and system settings provide the system resolver, so the actual environment may change when you switch between Wi-Fi and mobile data. If a destination resolves only on a particular network, such as an internal hostname, switching to another resolver may make it stop working. Before changing anything, record the hostname, its current resolution, and the network conditions.

When troubleshooting DNS, first determine whether the failure happens during resolution or after a connection is attempted. No address returned, a resolved address that times out, and a certificate error after the connection is established are different problems. Only the first points directly to the resolution path; the others may involve reachability, the destination service, system time, or handshake requirements. Repeatedly changing DNS without identifying the failure stage can hide the real cause.

Host mappings only change resolution results

[Host]
portal.example.com = 192.0.2.10
test.example.net = 198.51.100.20

The Host section sets a local mapping for a specified hostname. The address above is in a reserved documentation range and can't be used for real access. Host won't generate a certificate for a server or make an unreachable address reachable. Even if a hostname resolves to the specified IP, the server must still handle that hostname correctly. Don't treat Host as a quick fix for arbitrary website errors.

Before setting a real mapping, confirm that the destination address is stable and belongs to a service you're authorized to manage. Many sites use dynamic addresses, regional routing, or multi-address failover. Pinning one IP returned by a single lookup may work temporarily and then fail. The mapping will continue to override normal resolution after the network changes, so every Host entry should have a clear purpose and be removed when no longer needed.

Why address rules sometimes don't match

[Rule]
DOMAIN,portal.example.com,DIRECT
IP-CIDR,192.168.0.0/16,DIRECT,no-resolve
IP-CIDR6,fc00::/7,DIRECT,no-resolve
FINAL,PROXY

The first line selects a policy directly by hostname, without relying on the address ranges below to express the same intent. The last two lines cover only specific ranges and don't actively resolve a hostname for matching. If a specific internal hostname should always connect directly, an explicit domain rule is usually better than assuming it will always resolve to a private range and relying on an address rule to match indirectly.

A domain may resolve to both IPv4 and IPv6 addresses. Configuring an IPv4 range doesn't mean IPv6 connections will match the same rule; a single DNS lookup doesn't prove that every request uses the same address. If results are inconsistent, record the actual destination address and address family for that request, then compare them with the rule scope instead of adding duplicate domain entries.

Caches, GEOIP, and observation errors

DNS results may be cached by the client, system, or target app, and existing connections may keep using an old address. After changing Host or DNS settings, establish a new connection and check whether it uses the new result; if needed, clear the relevant cache using the app's supported method. Don't reset all network settings just to test one hostname. That introduces too many variables and makes it harder to tell which change mattered.

GEOIP uses a database classification of the destination address; it isn't an authoritative judgment about a domain's location. Content delivery networks and address reassignments can make the classification differ from expectations. If a service needs a fixed policy, put an explicit domain exception before GEOIP. Don't change an entire geographic routing group for one destination. To resolve a disagreement about classification, check the actual destination IP and the first matching rule.

06 URL Rewrite: Purpose and Safety Boundaries

URL Rewrite handles recognizable URL expressions and replacements; Rule determines the policy used for a connection. Both can appear in one configuration, but they aren't interchangeable. To route a domain through a proxy, write a routing rule. Consider a rewrite only when redirecting a specific old URL to a new one. Trying to fix every access problem with URL Rewrite can turn a straightforward connection issue into a harder-to-trace redirect problem.

Understand a simple redirect first

[URL Rewrite]
^http://example\.com/(.*)$ https://example.com/$1 302

This example describes a redirect from a specified HTTP address to an HTTPS address. The left side is a regular expression, the middle is the replacement target, and 302 at the end means a temporary redirect. The caret at the beginning anchors the match to the start of the string, and the dollar sign at the end anchors it to the end. The backslashes make the dots in the domain literal periods. The captured value is referenced in the replacement target using $1.

This example explains syntax; it doesn't require visiting the example domain or mean that every website should be rewritten by the client. Before using a rewrite, confirm that the destination service supports the new address, the path has the same meaning, and query parameters, sign-in callbacks, and resource references still work. A rewrite can change the request destination; it can't guarantee the new destination has the same content or permissions.

The expression scope must be explainable

In a regular expression, an unescaped period usually matches any single character, which can broaden the match. Omitting a start or end anchor may also let the expression match somewhere unexpected. Don't apply your intuition about domain suffixes to regular expressions: DOMAIN-SUFFIX and regex have different semantics. Regex doesn't automatically enforce the domain boundaries provided by the suffix rule.

Narrowing the match step by step is easier to verify than writing one expression to cover every URL. Start by testing a single hostname and a specific path, then decide whether to add a capture group. For each added wildcard, prepare an address that should not be rewritten. If you can't explain what a particular parenthesis or escape does, pause before deploying it; don't experiment on a configuration that's currently in use.

Redirects and transparent changes are different

A 302 redirect tells a client that supports redirects to request the target URL. That follow-up request still goes through resolution, connection, and rule processing. It doesn't silently turn the original connection into a different route. If the target matches another redirect, there may be several hops; two rules pointing in opposite directions can create a loop that prevents the page from loading.

To troubleshoot a redirect loop, first disable the new rewrite and check whether the original access works again. Then inspect the full chain from source URL to target URL. Browser caches and redirects from the site itself may also be involved, so verify with a new request rather than relying only on the final address in the browser. Be especially cautious with permanent redirects; avoid letting cached results interfere with testing.

HTTPS doesn't automatically expose the full path

An encrypted connection doesn't automatically reveal every request path and header to the client just because URL Rewrite appears in the configuration. Domain-level connection information and a full URL are not the same thing. Some HTTPS rewriting features depend on additional decryption conditions and certificate trust settings. This page doesn't require those features for routing, and expanding decryption to fix a domain rule isn't recommended.

If your goal is to route a specific domain directly or through a proxy, return to Rule instead of adding certificate-related settings. If you have an authorized testing need, limit the hostname scope, understand the implications for certificate pinning and sensitive sessions, and keep a way to undo the changes. If a rewrite doesn't trigger, don't immediately blame the expression; first check whether the client can see enough request information.

When maintaining a remote configuration, pay special attention to new rewrite sections. Updates can change not only routing but also destination URLs. If an update causes sign-in callbacks to fail, links to redirect differently, or resource URLs to change, compare URL Rewrite and Host as well as Rule. Keeping only the features you actually need makes future troubleshooting more manageable.

07 Common Rule Patterns and Combinations

When combining rules, describe the goal in one sentence, then break it down into exact exceptions, broader groups, and a fallback. The snippets below are independent and illustrate ordering; they contain no server details. Before using them, replace the example hostnames with confirmed destinations for your use case, and keep the original configuration for comparison. Don't skip validation or overwrite an existing file just because a snippet is short.

Proxy selected domains; connect directly to everything else

[Rule]
DOMAIN,api.example.com,PROXY
DOMAIN-SUFFIX,example.net,PROXY
FINAL,DIRECT

These rules define an explicit allowlist: only the exact API hostname and specified domain family use PROXY; everything else uses DIRECT. This can suit a use case with known, maintainable targets. If the app also depends on other resource domains, those connections will fall through to FINAL,DIRECT. If the API works but images or sign-in fail, look for missing hostnames before duplicating existing entries.

Document the service dependencies when maintaining this kind of configuration; don't rely only on the URL in the browser's address bar. Sign-in, static assets, and file uploads may use different hostnames. When adding a domain, keep the scope as narrow as possible and confirm it belongs to the same service flow before choosing DOMAIN or DOMAIN-SUFFIX. Adding a broad keyword without checking actual requests can change routing for other apps.

Connect selected traffic directly; proxy everything else

[Rule]
DOMAIN,router.example.net,DIRECT
IP-CIDR,192.168.0.0/16,DIRECT,no-resolve
GEOIP,CN,DIRECT
FINAL,PROXY

This example starts with a DIRECT exception for one exact hostname, then handles private addresses and GEOIP classification, and ends with a proxy fallback. The main difference from the previous snippet isn't the number of lines; it's the policy for unlisted destinations. Before evaluating a configuration, read FINAL first: the fallback determines what happens by default to new services, unknown domains, and unmatched addresses.

These rules don't cover every local network. Other networks may use different private address ranges, and IPv6 needs separate consideration. System and General bypass behavior may also take effect earlier. To reach internal services, add rules based on the actual addresses and hostnames rather than copying an unchecked list of ranges and assuming local network access is fixed.

Exact exceptions before a suffix rule

[Rule]
DOMAIN,login.example.com,DIRECT
DOMAIN,metrics.example.com,REJECT
DOMAIN-SUFFIX,example.com,PROXY
FINAL,PROXY

List exceptions for the sign-in and analytics endpoints first, then apply a shared policy to the rest of the domain family. REJECT here only illustrates where an exception goes; it doesn't mean the endpoint is safe to block in a real service. A service may combine analytics, initialization, and required features under one hostname. Rejecting the whole hostname could have side effects, so verify its role before keeping the rule.

DOMAIN can't distinguish paths under the same hostname, and adding multiple copies of the same domain rule won't change that. If different paths need different handling, first reconsider whether path-based handling is necessary instead of adding a slash to the domain field. Routing rules and URL Rewrite have different capabilities; combining snippets of syntax can't turn one rule type into another.

Keep one decision order when merging configurations

Merging two rule lists doesn't mean joining the files end to end. Remove duplicate section headers and intermediate FINAL rules, then review the combined list in this order: service exceptions, domain groups, address ranges, and fallback. Identical duplicate lines usually add reading overhead. Different policies for the same condition create a real conflict: the earlier rule takes effect, while the later one may mislead whoever maintains the configuration.

Manage subscription groups separately from rule-based routing. A subscription rename shouldn't make the traffic route hard to explain, and before deleting a subscription, confirm that the selected proxy is still valid. For organizing entries from multiple sources, see how to group and update multiple subscriptions and remove duplicate entries. After organizing the server list, verify separately that the rules still use the intended route.

Add one combined goal at a time: for example, first set up direct access to internal addresses, then proxy specific domains, and only then add rejection exceptions. At each step, record one expected match and one counterexample. Even a short configuration is easier to troubleshoot when every line has a clear purpose. If something goes wrong, you can quickly undo the latest set of changes without rebuilding all the rules.

08 Rule Validation, Troubleshooting, and Maintenance

Validating routing means connecting the request target, matched rule, selected policy, and final connection result. A page may load from cache, and a failure may be caused by the server or destination service. Neither result alone proves a rule is correct. Start troubleshooting with the easiest current state to verify, then narrow down the connection process one layer at a time. Avoid changing several independent settings at once.

Step 1: Fix the test conditions

Record the current network, selected server, Global Routing mode, and Config file name. Confirm that the connection is on and Config is in use, then choose a target whose expected route you can explain. Don't switch servers or import the subscription again yet. If test conditions keep changing, you won't know whether a later success came from a rule change or a network recovery.

Check whether the configuration is saved and enabled, and whether a remote refresh overwrote local changes. To test a new rule, start a new connection and avoid reusing an old session if possible. Close and reopen the relevant browser pages, or quit and restart a standalone app. There's no need to reset system networking as a first step. Each action should eliminate a specific variable.

Step 2: Check the target and first matching rule

In the connection logs or diagnostic information available in the app, find the hostname, destination IP, rule, and policy for the request. The logged API hostname may differ from the page URL; use the actual request as your reference. First confirm that the request entered the active configuration. Then check whether an earlier suffix, keyword, address, or rejection rule matched it. Don't search only for the line you just added.

If the expected hostname isn't visible, the request may contain only an address, encrypted connection details may be limited, the app may use a different hostname, or the log may cover a different scope. Don't guess and add dozens of domains. First test a more observable target using the same rule type, confirm the basic matching behavior, and then investigate the original app. USER-AGENT rules especially require proof that the relevant identifier is available.

Step 3: Separate a correct policy match from a successful connection

Observed resultCheck firstNext step
Unexpected REJECT matchKeyword scope and order of exact exceptionsNarrow the rule and start a new connection
PROXY matched, but the connection failedServer selection, authentication, and destination reachabilityTest the same destination in Proxy mode
DIRECT matched, but the connection failedLocal network, DNS, and internal routingCompare the actual destination address and network conditions
Always falls through to FINALTarget field, rule type, and visible informationCheck whether the hostname and address meet the rule conditions
No change after editingSelected file, cache, and existing connectionsCheck that the file is saved and enabled, then make a new request

Connectivity Test can help check the server connection, but it can't replace a full access test for a specific service. The test target may differ from the actual destination, and the protocol or request type may differ too. Likewise, upload and download readings in Data only show traffic within the relevant statistics scope; traffic volume alone doesn't prove that a particular rule matched. See the guide to traffic statistics on the Data page.

Step 4: Keep evidence and make the smallest rollback

If a problem starts after adding configuration, first disable the most recently added group of rules or rewrites, or restore the saved configuration for comparison. If that fixes the issue, reintroduce changes one at a time instead of resetting everything. Record the target, expected policy, actual first match, and failure stage. This is more useful than saying “it sometimes won't load” when determining whether the problem is rule order, resolution, or the proxy connection.

Before sharing troubleshooting materials, remove subscription links, authentication fields, access tokens, and query parameters containing personal information. Use example.com and reserved addresses to demonstrate configuration structure; there's no need to disclose real credentials. Example domains in rules are usually not sensitive, but connection logs may include full paths and session information. Review each item before sharing instead of forwarding the entire configuration.

Set up repeatable maintenance checks

After each rule update, retest at least one proxy destination, one direct destination, and one counterexample that should be excluded. If you use REJECT, also confirm that its scope hasn't expanded. After changing networks, focus on internal addresses and DNS; after changing servers, check the proxy path; after updating a configuration, review rule order and new sections. The test set can be small, but keep it consistent and relevant to your use case.

For initial connection steps, return to the quick-start guide. For downloads or system permission prompts, see the installation and permission guidance on the download page. For common usage questions, visit the FAQ. The goal of this rules reference is to make every outcome traceable to its conditions, not to keep adding rules until one visit happens to work.