explaingit

loyalsoldier/clash-rules

📈 Trending26,503Audience · generalComplexity · 1/5ActiveLicenseSetup · easy

TLDR

Pre-built routing rule sets for Clash proxy tool that automatically categorize websites as direct-access, proxy-required, or blocked, updated daily for the Chinese internet landscape.

Mindmap

mindmap
  root((repo))
    What it does
      Routing rules for Clash
      Categorizes websites
      Blocks ads automatically
    Rule categories
      Direct access sites
      Proxy-required sites
      Blocked domains
      IP ranges
    Maintenance
      Daily auto-rebuild
      GitHub Actions
      Community sources
    Use cases
      Configure Clash proxy
      Block advertisements
      Access restricted sites
    Audience
      Clash users in China
      Non-technical users
      Proxy tool operators

Things people build with this

USE CASE 1

Add routing rules to your Clash config to automatically route traffic to the right servers without manual setup.

USE CASE 2

Block advertising domains across all your devices by importing the ad-blocking rule list into Clash.

USE CASE 3

Access websites blocked by your ISP or government by using the proxy-required rule list that routes them through a VPN.

USE CASE 4

Keep your routing rules current automatically, the lists update daily without you having to manually refresh them.

Tech stack

ClashGitHub ActionsDomain lists

Getting it running

Difficulty · easy Time to first run · 5min
Use it freely, but any project you distribute that includes this code must also be GPL-licensed and open source.

In plain English

This repository provides routing rule sets for Clash, a network proxy tool (a program that routes your internet traffic through different servers) popular in China for accessing blocked websites. The rule sets are curated lists of domain names and IP addresses that tell Clash how to handle different types of traffic: which sites to access directly, which to route through a proxy, and which to block entirely (like ads). The README is entirely in Chinese, which reflects the primary audience. The project is built for users of Clash and its variants (ClashX Pro, Clash for Windows, etc.) who want a well-maintained, comprehensive set of routing rules rather than building their own from scratch. The rule lists are automatically rebuilt every day at 6:30am Beijing time using GitHub Actions (an automated task runner), pulling from several community-maintained domain lists. They cover: websites to access directly from China mainland, websites that need a proxy, advertising domains to block, Apple and Google services accessible directly in China, Telegram IP addresses, and Chinese mainland IP ranges. For a non-technical user in China who uses Clash for internet access, this is a practical plug-and-play configuration resource. You paste the provided URL into your Clash config file and your traffic routing stays current automatically. For users outside China, this repository has limited direct utility, it's specifically designed around the Chinese internet landscape and the Great Firewall context.

Copy-paste prompts

Prompt 1
How do I add these Clash routing rules to my ClashX Pro or Clash for Windows configuration?
Prompt 2
What's the difference between the direct-access rules and proxy-required rules in this repository?
Prompt 3
Can I use these Clash rules outside of China, or are they only designed for the Chinese internet?
Prompt 4
How do I set up automatic daily updates of these Clash rules in my proxy client?
Open on GitHub → Explain another repo

Generated 2026-05-18 · Model: sonnet-4-6 · Verify against the repo before relying on details.