This guide explains how to use remote rule sets in Shadowrocket to route matching traffic through a selected policy. It is for users who already have a working configuration and their own subscription. You’ll see where a RULE-SET entry belongs, how to pair it with a policy, why rule order matters, and how to check whether an update and a match actually took effect. The example URL uses a reserved placeholder domain; replace it only with a rule-set URL you trust and are authorized to use.
What a remote rule set does
A rule set is a collection of match conditions that can be referenced from the active configuration instead of copying every condition into the local [Rule] section. A remote rule set lets its maintainer publish changes at a URL; Shadowrocket can retrieve that content when the configuration or rule set is updated. This can make a long list easier to maintain, but it also means the URL and the data it serves become dependencies of your routing setup.
A RULE-SET rule connects two things: the remote list to evaluate and the policy to use when a request matches that list. The list describes what to match; the policy determines where matching traffic goes. In the example below, PROXY is a policy name, not a universal instruction that works in every configuration. It must correspond to a policy available in your active setup. If your configuration uses a different name, use that exact name instead.
Remote does not mean that every request is sent to the rule publisher. The remote URL supplies the rule data; after the data is available to the active configuration, Shadowrocket evaluates requests against the rules and applies the configured policy. How often data changes become available depends on the configuration’s update behavior and whether a refresh succeeds. If the list cannot be retrieved, don’t assume a newly published entry is already in use.
Also distinguish a remote rule set from a subscription containing connection details. A rule set controls matching and routing decisions; your own subscription supplies connection information and may supply policies or other configuration elements. A rule list cannot replace a usable connection, and adding a rule does not create a policy that is missing from the configuration.
Prepare the URL and policy before editing
Before adding an entry, confirm which configuration is active in Config and which policy names it defines. A syntactically valid rule can still fail to achieve the intended route if it refers to a nonexistent policy, points to an inaccessible URL, or uses content in a format the parser does not accept. Use a source that provides a plain-text rule list compatible with Shadowrocket’s supported rule syntax, and check its documentation if the format or update method is unclear.
Use a placeholder when learning the structure rather than copying a random live list. The reserved example.net domain below is illustrative and is not a real rule source. Replace the URL with the exact address provided by a source you trust; do not add a URL merely because it appears in an example. The policy shown is also illustrative, so confirm the spelling against your own configuration.
[Rule]
RULE-SET,https://rules.example.net/my-rules.list,PROXY
GEOIP,CN,DIRECT
FINAL,DIRECT
The first line under [Rule] asks Shadowrocket to evaluate the remote set and use PROXY for matching requests. The following examples provide other routing decisions. They are not a universal recommended policy: adapt them to the rules and policies you actually use. In particular, a policy named PROXY must exist and be usable. If the active configuration has a differently named policy, substitute that exact name.
Before saving, check the URL for accidental spaces, missing characters, or a copied trailing punctuation mark. If the list requires access credentials, an account, or a special subscription mechanism, follow the source’s documented setup rather than exposing credentials in a public configuration. Treat a subscription URL and any embedded token as sensitive: avoid posting it in screenshots, logs, or shared files.
Add the entry and preserve rule order
Open Config, select the configuration you intend to use, and edit its [Rule] section. Put the RULE-SET entry where its intended matches can reach it. Rules are evaluated in order, so an earlier broad rule may decide the route before a later remote set is considered. A remote list placed near the bottom cannot override a matching rule that has already been applied.
-
Confirm the active file
Open Config and identify the configuration currently selected for use. If you edit a different file, the change may be valid but have no effect on current traffic. Keep a copy of the original content so you can revert if the result is unexpected.
-
Check its policies
Find the policy names available in that configuration. Make sure the policy in the final field of your
RULE-SETentry matches one of them exactly. Do not assume that a label shown in an example exists in your own setup. -
Add the remote rule
In the
[Rule]section, add the entry using the URL and policy supplied for your setup. Keep commas between fields and avoid inserting line breaks inside the URL. Confirm that the configuration remains structurally valid after editing. -
Review earlier rules
Look above the new entry for rules that could already match the same traffic, such as a domain-specific rule or a broad network rule. Reorder only when you understand the intended precedence; avoid moving unrelated rules just to make the new entry appear earlier.
-
Save and test
Save the configuration, make sure it is active, and test a domain that the remote list is documented to match. Check the connection log for the request and its selected rule or policy. A successful connection by itself does not prove that the intended rule matched.
Rule order is especially important when using broad match conditions. For example, a matching domain rule placed above a remote set may send that domain to DIRECT before the remote set can assign PROXY. Conversely, an early catch-all rule can prevent later specific rules from being useful. Keep a deliberate sequence: specific exceptions first where needed, then the remote set and other broader decisions, with a final fallback such as FINAL at the end. The right order depends on the configuration’s purpose; the example is a structure to reason about, not a one-size-fits-all file.
Rule order is part of the routing policy
If a test request follows the wrong route, inspect the rules above the remote set before changing its URL. The first applicable rule may already be deciding the outcome.
Update and verify the remote list
Saving a rule entry and retrieving its remote contents are separate checks. First, verify that the active configuration recognizes the entry. Then trigger the update using the control available for that configuration or rule set in your current Shadowrocket interface. Labels and available actions can vary with the configuration format, so use the controls shown for the item rather than relying on a menu name from a different setup.
After refreshing, check for an update or retrieval error before testing traffic. A successful refresh means the list could be obtained or processed at that time; it does not prove that every intended domain is present, that the rule order is correct, or that the selected policy can connect. Likewise, a visible URL in the configuration does not prove the remote content is current. If the list is maintained by another party, consult its change notes or source documentation to understand what it is meant to match.
- Check reachability: Confirm the device has working network access and that the exact URL opens or can be retrieved as the source documents. If access requires credentials or a particular network, an update may fail even while other connections work.
- Check the response: A URL that opens a webpage, sign-in prompt, error page, or download wrapper may not return the plain-text rule content the configuration expects. Verify the actual response format with the source.
- Check the active configuration: Make sure the entry belongs to the file selected in Config. A refresh of one configuration does not automatically prove another active file has been updated.
- Check the match: Use a test domain that the rule source explicitly documents, then inspect its request in the connection log. Compare the shown rule or route with the intended policy.
- Check the fallback: If no entry matches, traffic may continue to another rule or the final fallback. That outcome is different from a remote-list retrieval failure.
For a controlled test, choose one documented domain, close or reload the app that made the request, and generate a fresh request rather than relying on a page already open in a browser. Observe the connection log while that request occurs. If it shows a different rule, read the earlier rules in sequence and check whether the domain is covered by a broader match. If the request appears to use the intended policy but fails to connect, test the policy’s underlying connection separately; rule matching and connection health are different layers.
Keep a record of what you changed: the active Config, the rule entry, whether the refresh succeeded, the test domain, and the log result. Change one thing at a time. Replacing the list, changing DNS, switching policies, and reordering rules simultaneously makes it difficult to identify the cause of a new result. Avoid sharing full logs or configuration files unless you have removed subscription URLs, credentials, and other private information.
Choose a maintenance approach that fits your setup
Remote lists reduce the need to paste a large collection of rules into a local file, but they do not remove the need to review changes. A list can change its contents, become unavailable, or stop matching the domains you care about. Before relying on it for important traffic, understand who maintains it, what categories it covers, how it is updated, and what happens when it cannot be retrieved. If you cannot confirm those details, keep the routing behavior conservative and test it before depending on it.
Choose between a remote set and local rules
Remote rule set
- Useful for a maintained list that changes over time
- Requires a reachable URL and compatible rule content
- Needs refresh and match checks after relevant changes
Local rules
- Useful for a small number of personal exceptions
- Can be reviewed directly in the active configuration
- Must be edited manually when the desired matches change
Use a remote set for rules you intentionally depend on as an externally maintained list; keep small, clearly understood exceptions local when that is easier to audit.
A hybrid setup can be practical: a remote set handles a broad, maintained category, while a few local rules express exceptions specific to your own needs. Keep those exceptions near the top only when they must take precedence over the remote list. Add a short note beside manually maintained rules if the configuration format supports comments, so future edits do not accidentally reverse the intended order.
If a refresh fails, don’t keep changing unrelated routing settings. Check the URL and source status, confirm that the device can reach it, and verify that the returned content uses a supported format. If refresh succeeds but a test goes to the wrong route, inspect the active configuration, policy name, and rule precedence. If the connection log shows the intended policy but the destination still fails, investigate the connection and destination separately. This sequence separates retrieval, matching, policy selection, and connectivity instead of treating them as one problem.
Does adding RULE-SET create a proxy policy?
No. The policy field selects a policy already available in your active configuration. Check its exact name in Config; if it is missing, fix the configuration or select an existing policy before testing.
The list refreshed, so why did my test use another route?
Refresh confirms retrieval or processing, not that a particular request matched. Check the connection log, then review earlier rules and whether the test domain is included in the list.
Can I use any URL that returns text?
Not necessarily. The response must contain rule content in a format Shadowrocket accepts, and the URL must be reachable under your network and access conditions. Use the source’s documented endpoint and format.
Remote rule sets are most reliable when their scope is clear, their policy exists, their format is compatible, and their behavior is verified in the log. Treat the URL as a dependency, preserve a copy of your working configuration, and test representative requests after changes. If you need help with the app’s platform-specific installation information, use the download guide; iPhone and iPad editions are a one-time $2.99 App Store purchase, while Mac, Windows, Android, and Linux editions are free from the download page.