gitwtfhub

wtf is v2ray-rules-dat?

loyalsoldier/v2ray-rules-dat — explained in plain English

Analysis updated 2026-05-18

19,736Audience · ops devopsComplexity · 2/5LicenseSetup · easy

TL;DR

Daily-updated routing rule data files (IP and domain lists) for V2Ray and compatible proxy tools, enabling smart traffic routing based on geography and content categories.

Mindmap

mindmap
  root((repo))
    What it does
      IP geolocation data
      Domain categorization
      Traffic routing rules
    Data sources
      MaxMind GeoLite2
      GFWList blocklists
      CDN provider lists
    Compatible tools
      V2Ray
      Xray-core
      Clash-Meta
    Use cases
      Self-hosted proxies
      Smart traffic routing
      Content filtering

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

Why would anyone build with this?

REASON 1

Route Chinese domestic traffic directly and foreign traffic through a proxy in a self-hosted setup.

REASON 2

Block advertising and malware domains while allowing legitimate traffic based on geographic origin.

REASON 3

Replace official V2Ray routing data with more comprehensive, frequently-updated IP and domain lists.

REASON 4

Configure Clash-Meta or Hysteria to intelligently split traffic between direct and proxied connections.

What's in the stack?

V2RayXray-coreGitHub ActionsGeoIPDNS filtering

How it stacks up

loyalsoldier/v2ray-rules-datdatalab-to/suryaahmetb/kubectx
Stars19,73619,73419,732
LanguagePythonGo
Setup difficultyeasymoderateeasy
Complexity2/53/51/5
Audienceops devopsdeveloperops devops

Figures from each repo's GitHub metadata at analysis time.

How do you spin it up?

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.

Wtf does this do

This repository provides enhanced routing rule data files for V2Ray and compatible proxy tools. V2Ray is a network proxy framework used to route internet traffic through different paths based on rules, for example, sending Chinese domestic websites through a direct connection while routing foreign websites through a proxy. The two core data files it produces are geoip.dat (geographic IP address data) and geosite.dat (domain name categorizations), which replace the official versions provided by V2Ray with more comprehensive and frequently updated alternatives. The geoip.dat file maps IP address ranges to countries and CDN providers such as Cloudflare, Google, Netflix, and Telegram, allowing routing rules like "if the destination IP belongs to Cloudflare, send it directly." The China IP data merges multiple sources including MaxMind GeoLite2 and operator-specific lists for more accurate coverage. The geosite.dat file categorizes domain names into groups such as Chinese domestic sites (direct connection), sites blocked by China's Great Firewall (proxy needed), advertising domains (blocked), and Windows telemetry domains (optionally blocked). It incorporates data from GFWList, EasyList, AdGuard DNS Filter, and other well-known blocklists. Both files are rebuilt automatically every day at 6 a.m. Beijing time via GitHub Actions to stay current. They are compatible with V2Ray, Xray-core, Clash-Meta, Hysteria, Trojan-Go, and similar proxy tools. Someone running a self-hosted proxy setup to manage network traffic in a China-adjacent context, routing local vs. foreign traffic intelligently, would use these files as drop-in replacements for the official routing data.

Yoink these prompts

Prompt 1
How do I set up V2Ray with these geoip.dat and geosite.dat files to route Chinese domestic sites directly and foreign sites through a proxy?
Prompt 2
What's the difference between the official V2Ray routing data and the enhanced data in this repository, and why would I use this instead?
Prompt 3
Show me how to configure Clash-Meta to use these routing rules to block ads and split traffic by geography.
Prompt 4
How often are these routing data files updated, and how do I ensure my proxy tool always uses the latest version?
Prompt 5
Can I use these geosite.dat and geoip.dat files with Trojan-Go or Hysteria, or are they only for V2Ray?

Frequently asked questions

wtf is v2ray-rules-dat?

Daily-updated routing rule data files (IP and domain lists) for V2Ray and compatible proxy tools, enabling smart traffic routing based on geography and content categories.

What license does v2ray-rules-dat use?

Use it freely, but any project you distribute that includes this code must also be GPL-licensed and open source.

How hard is v2ray-rules-dat to set up?

Setup difficulty is rated easy, with roughly 5min to a first successful run.

Who is v2ray-rules-dat for?

Mainly ops devops.

View the repo → Decode another repo

This repo across BitVibe Labs

Don't trust strangers blindly. Verify against the repo.