Differences between mihomo core and the original Clash core: protocols, rule providers, and configuration syntax

Compare mihomo (Clash Meta) with the original Clash core, including added protocols, rule-provider syntax, DNS enhancements, TUN support, and configuration migration tips.

First, distinguish the client, core, and subscription

Here, “original Clash” means the open-source base core—not Clash Premium or modified versions bundled with clients. Older guides often refer to all of these as Clash, so finding a field in an old configuration only proves that the field is present; it does not prove the original core can use it. Check rule providers and TUN support in particular: some features once provided by Premium have equivalents in mihomo, but defaults and supported options may differ.

The client imports subscriptions, manages the system proxy, and displays connections. The core parses the configuration, establishes outbound connections, and matches rules. First, note the core name and version shown in the client’s core information or startup logs. If you can run the mihomo binary directly, check the version with mihomo -v. The client installer’s version number is not the core version, and the format name in a subscription URL does not prove that it outputs the right fields.

Added protocols: check the type and transport settings

ProtocolWhat to check when migrating
ssBoth cores support Shadowsocks, but check that the current core supports the encryption method and plugin options you use.
vlessCheck the UUID, transport, and TLS settings. For nodes using REALITY, also check reality-opts—changing the VMess type to VLESS is not enough.
hysteria2This is a different protocol from hysteria. The client and server must use the same protocol; check the password, certificate name, and UDP reachability.
tuicCheck that the client and server use the same protocol version and authentication fields, and make sure the network allows access to the server’s UDP port.

When migrating a subscription, first import a configuration explicitly intended for mihomo. Then inspect proxies in the active configuration, or check the node list downloaded by proxy-providers. A node’s display name, even “HY2,” is no substitute for type: hysteria2. If the startup log reports an unknown proxy type, check the core and subscription output first. If the configuration loads but the handshake fails, check authentication, certificates, or transport instead. Don’t conflate these two kinds of errors.

For example, if a server accepts Hysteria2 on 443/UDP, opening an HTTPS page on the same host only proves that the TCP service is reachable—not that the UDP path works. For comparison, keep a known-working TCP node and test the same destination on the same network.

Rule providers: define sources separately from rule references

Being able to write DOMAIN-SUFFIX in rules does not mean a core can load rule-providers. In mihomo, rule-providers defines the source and format of a rule set, while RULE-SET determines where it is matched and which policy applies when it matches. The example below uses a local file to keep remote download failures separate from rule-matching failures.

rule-providers:
  local-domains:
    type: file
    behavior: domain
    format: yaml
    path: ./rules/local-domains.yaml
rules:
  - RULE-SET,local-domains,DIRECT
  - MATCH,DIRECT

Add the following content to rules/local-domains.yaml in the core’s working directory. A client may use a separate working directory for its core, so don’t assume it’s the same directory as the subscription file.

payload:
  - "example.com"
  - "+.example.net"
  • Entries under behavior: domain are domain matches. If the file contains entries with rule types, such as DOMAIN-SUFFIX,example.net, use the matching classical behavior instead.
  • When migrating remote rule sets, check the source, behavior, format, and cache path for each one. Renaming a YAML file to .mrs does not change its contents. mihomo’s MRS rule sets are for domain or ipcidr behavior.
  • Rules are evaluated in order. Both rules in this example use direct connections, so check the connection details to see whether RULE-SET or the final MATCH rule was hit. A webpage loading successfully isn’t enough to tell.

DNS: distinguish response addresses, upstream resolvers, and routing policies

fake-ip is not a new mihomo feature. In this mode, a domain can resolve to a mapped address. Once the application’s connection is intercepted, the core uses that mapping to recover the domain. 198.18.0.1/16 is a commonly used fake-ip-range value. If an application receives a mapped address but its connection does not pass through the same core, it may fail to connect. Check the interception path first instead of repeatedly changing upstream DNS servers.

When migrating, check settings by query type

  • nameserver provides upstream resolvers for general queries. nameserver-policy lets you choose upstreams for specific domains. Choosing an upstream resolver and choosing which proxy carries the actual connection are two separate decisions.
  • proxy-server-nameserver resolves the hostnames of proxy servers. If a node’s address is a hostname, make sure resolving it does not depend on the same proxy connection that has yet to be established.
  • fake-ip-filter can return real addresses for matching names. If a local network application needs a real address, test that name first, then decide whether to keep an exception. Broad exclusions change how other domains resolve.

TUN: test route interception separately from the proxy port

The system proxy works only when an application respects the system proxy settings. For example, an application using the local 127.0.0.1:7890 mixed-port sends traffic to the core through its proxy listener. TUN uses a virtual interface and system routes, so it can capture traffic from applications that ignore system proxy settings; what it captures depends on routing, permissions, and the client’s implementation. Don’t assume TUN fields from an old Premium configuration are universal settings for the open-source base core.

In mihomo, tun.enable turns TUN on or off; auto-route configures routes automatically, and stack lets you choose system, gvisor, or mixed for your environment. dns-hijack is a separate setting. A common value, any:53, matches regular DNS requests that enter the intercepted path; it does not prove that in-app DNS over HTTPS is also intercepted. A successful configuration load and successful interface creation are two separate checks. For the latter, check the client logs and system routing status.

To test, first use a browser to confirm that the proxy port works. Then enable TUN, turn off the system proxy, and connect to a known destination using an application that has no explicit proxy configured. If no connection appears in the logs, check interface permissions and routing first. If a connection appears but uses the wrong policy, check the rules and DNS next. If a VPN or another TUN tool is already running, test with just one tool at a time to avoid two virtual interfaces changing the default route.

Configuration migration steps and rollback criteria

  1. Keep the old configuration. Back up the active configuration and local overrides, and note the listening ports, selected policy-group options, and DNS mode. Don’t let the old and new cores use 7890 at the same time. Subscription URLs may contain access tokens; remove the URL and node credentials before sharing logs.
  2. Verify that the configuration loads first. In a separate test directory, run mihomo -t -f config.yaml to check the configuration. If you use relative rule paths, make sure the test and actual run use the same working-directory settings. Passing this check does not guarantee that nodes can complete a handshake or that every platform feature can be enabled.
  3. Test one node and one destination at a time. Turn off TUN first, then make a connection explicitly through the proxy port and confirm that the connection details show the expected outbound node. Proxy groups refer to nodes by name, so check local overrides again if a subscription update renames a node.
  4. Restore rule sets, DNS, and TUN one at a time. Change only one layer at a time and keep the same test destination for comparison. If enabling TUN disrupts local network access, turn it off and confirm that the original routes are restored before comparing interface and DNS changes. If the problem started only after a subscription update, compare the active configurations before and after the update; reinstalling the client should not be your first step.
Download the latest version of Clash