What each file is responsible for

  • geosite.dat: the domain category database. Rules like GEOSITE,netflix look up domains and keywords here.
  • geoip.dat or geoip.metadb: IP ranges mapped to countries and regions. GEOIP,CN,DIRECT reads this one.
  • Country.mmdb: a MaxMind-format IP database that some profiles and older setups use for the same country lookup.

These files ship as a snapshot alongside the core. They do not refresh themselves when your rules change. A newly launched service domain may take weeks to reach the upstream dataset and longer to reach your machine.

SponsoredWhere does the subscription link come from?Our partner provider gives you 1 GB of high-speed Hong Kong data at signup — import it in one click.Get high-speed nodes

Updating by hand

Clash Verge Rev has an update GeoData button in settings that re-downloads the files into the core directory. Restart the core afterwards — a running core does not hot-reload these databases.

For clients without that button, download the files and overwrite them in the core directory. Keep the filenames exactly as the config references them; renaming produces a "file not found" error at startup.

Letting the core update itself

mihomo can refresh them on a schedule. Add this at the top level of your YAML:

geodata-mode: true
geo-auto-update: true
geo-update-interval: 24

geo-update-interval is in hours, so 24 means once a day. Once automatic updates are on, stop overwriting the files by hand — the two mechanisms fight each other.

One caveat: the update is a request made by the core itself. If the proxy is not up yet when the timer fires, the download usually fails and leaves a clear error line in the log. That is not a crisis; it retries once you are connected.

Pointing at a different mirror

When the default source is blocked or slow, specify your own:

geox-url:
  geoip: "https://example.com/geoip.dat"
  geosite: "https://example.com/geosite.dat"
  mmdb: "https://example.com/Country.mmdb"

List only the entries you are overriding and leave the rest at their defaults. Each URL has to return the file itself. If it points at an HTML download page, the core saves a page of markup, parsing fails, and the error message is rarely as explicit as you would like.

Rules still behaving oddly after an update

Separate a data problem from an ordering problem. Rules are evaluated top to bottom and matching stops at the first hit, so a new GEOSITE rule placed below a broader rule never gets its turn. Move it temporarily to the very top and retest — that one experiment tells you which of the two you are dealing with.

These database files decide where your traffic goes. If you use a third-party mirror, pick a source you actually trust rather than the first URL in a search result.