explaingit

hackl0us/ss-rule-snippet

11,266JavaScriptAudience · generalComplexity · 1/5LicenseSetup · easy

TLDR

A ready-made collection of proxy routing rules for Surge, Clash, Quantumult X, and Shadowrocket that users can import directly without building their own configurations from scratch.

Mindmap

mindmap
  root((repo))
    Supported apps
      Surge
      Quantumult X
      Shadowrocket
      Clash
    Rule categories
      Basic lazy rules
      App specific rules
      Optional rules
      Functional rules
    No ad blocking
      Breaks frequently
      Slows proxy tool
    Contributions
      Pull requests
      GitHub issues
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

Things people build with this

USE CASE 1

Import a complete proxy routing configuration for Surge, Clash, or Shadowrocket without writing any rules yourself

USE CASE 2

Set up correct routing for specific Chinese streaming services or social apps that need special proxy handling

USE CASE 3

Configure advanced proxy scenarios such as fixing Siri latency or enabling global proxy on older Surge versions

Tech stack

JavaScript

Getting it running

Difficulty · easy Time to first run · 30min

Requires an existing proxy client app such as Surge, Clash, Quantumult X, or Shadowrocket with a valid proxy server already configured.

Free to share and adapt for non-commercial purposes only, with attribution and under the same license terms.

In plain English

SS-Rule-Snippet is a curated collection of network proxy routing rules for several popular proxy client apps used primarily by Chinese-speaking users: Surge, Quantumult X, Shadowrocket, and Clash. These proxy tools route internet traffic through servers to access content that might otherwise be blocked, and they rely on rule files to decide which traffic to proxy and which to send directly. This repository provides ready-made rule files for each supported app so users do not have to build their own configurations from scratch. The rules are organized into categories. Basic rules cover the minimum needed for typical use and form what the project calls "lazy rules," meaning pre-built complete configurations a user can import without modification. App-specific rules handle special routing needs for particular services like streaming platforms or social apps. Optional rules target specific user groups such as students or frequent video watchers. Functional rules address advanced scenarios like fixing high latency in Siri or enabling global proxy on older Surge versions. The README explains in detail why the project does not include ad-blocking rules. The main reasons are that ad-blocking rules change frequently and become outdated quickly, proxy tools have limited matching capabilities compared to dedicated browser extensions, and loading too many rules slows down the proxy tool or can even cause it to crash, especially on jailbroken devices. The author recommends using dedicated browser extensions like uBlock Origin or AdGuard instead. Contributions are accepted through pull requests and GitHub issues. The README notes that verifying whether a domain is genuinely needed often requires packet capture rather than just trying to visit it in a browser. The project is written primarily in Chinese and is licensed under Creative Commons Attribution-NonCommercial-ShareAlike 4.0, meaning it can be shared and adapted for non-commercial purposes with credit.

Copy-paste prompts

Prompt 1
How do I import ss-rule-snippet lazy rules into Surge to get a working proxy configuration with no manual rule writing?
Prompt 2
I use Clash and want routing rules from ss-rule-snippet, which files should I use and how do I add them to my config?
Prompt 3
The ss-rule-snippet project does not include ad-blocking rules, what browser extension should I use alongside my proxy setup?
Prompt 4
How do I submit a new domain rule to ss-rule-snippet and verify the domain actually needs to be proxied?
Open on GitHub → Explain another repo

← hackl0us on gitmyhub — every repo by this author, as a profile.

Verify against the repo before relying on details.