The system initiates on-demand connections when the configured conditions are met.
mihomo core
GPL-3.0-licensed open source
iOS / iPadOS / macOS
Configuration workspace
Clash routing rules and configuration management
Every connection involves two checks: first, whether traffic reaches the client; then, where the configuration sends it. System proxy, TUN mode, and on-demand connections affect the first step. Rules, proxy groups, and outbound protocols determine the second. When troubleshooting, identify which step failed instead of changing every setting at once.
In rule mode, the configuration is checked from top to bottom. Once a rule matches, evaluation stops. In this example, Apple domain suffixes are matched to Direct first, then the destination's geographic location is checked. Remaining connections go to the proxy group named Proxy. Make sure that group is defined in your configuration. Unlike global mode, rule mode can send requests from different apps through different outbound routes. After making a change, start a new connection and check the matched rule and actual route in its details.
config.yaml
Local file · Managed manually
Remote subscription
Get configuration from a URL
Update subscription
A subscription URL retrieves a configuration; the configuration file is what the core loads. Give your everyday and test configurations distinct names, then check which one is active after importing. Refreshing a remote profile may replace its contents, so keep custom rules in a local copy or use the client's override feature. Update options vary by client, so check whether scheduled refreshes and overrides are supported when switching clients. Hide your subscription URL before sharing screenshots of errors.
TUN modeEnabled
Traffic capture methodVirtual network interface
The system proxy mainly serves apps that read the system proxy settings. For apps that don't, consider enabling TUN mode in a supported client so traffic enters the core through a virtual network interface. First-time setup may require system authorization, depending on the client. After enabling it, test the target app, then check LAN devices, your company VPN, and behavior after waking from sleep. If a problem occurs only with TUN enabled, turn it off and compare routing and DNS behavior.
VPN configurationAdded
On-demand connectionEnabled
Trigger conditionsConfigured by the client
On iPhone or iPad, connect manually once first. Confirm that you've allowed the client to add a VPN configuration, then set up on-demand connections. This lets the system try to connect when the relevant conditions are met; it doesn't keep the device online indefinitely after the screen locks. Available network conditions vary by client, so check the connection on both Wi-Fi and cellular. If it reconnects after you disconnect manually, check the on-demand setting and whether another VPN configuration is active.
Core projectmihomo
Code licenseGPL-3.0
Configuration formatYAML
The client imports profiles, switches between them, and displays status; the core parses the configuration and handles connections. mihomo supports multiple proxy protocols, but whether a protocol or field works depends on the core version integrated into the client and its supported features. When migrating a configuration, first confirm that basic proxies and groups load, then test protocol-specific fields, rule sets, and DNS settings. If you see an unsupported protocol or unknown field, check the startup logs rather than assuming compatibility based on the client name.
The target app isn't listed in Connections
Quit and reopen the target app to avoid reusing an existing connection. If new requests still don't appear, check whether the app reads the system proxy settings or another VPN is capturing network traffic. Changing the rule order usually won't help at this stage.
A rule matched, but traffic took the wrong route
A matched rule selects a policy, not necessarily the server ultimately used. Open the relevant proxy group and check whether it uses a manual selection or automatic routing. After changing the selection, start a new connection and check its details. See the glossary for related terms.
Downloads and app store links
Get a client for your operating system
Choose a client for the device you use most; there's no need to switch operating systems just to match another device. To compare configuration overrides, TUN mode, or maintenance status, see the client comparison. If a work or school device restricts network extensions, check with your administrator first.
Check your chip under Apple menu > About This Mac. Choose the Apple Silicon build if it says Apple chip, or the Intel build if it says Intel processor. For your first connection, test a browser with the system proxy enabled. If an app ignores the system proxy, then consider whether TUN mode is needed. When switching clients, turn off the old client's proxy and launch-at-startup settings to prevent both apps from competing for system settings after a restart.
For iPhone and iPad, start by checking the Clash Plus App Store listing and system requirements. After installing, open the app, import a configuration, and approve the system's VPN authorization prompt when connecting for the first time. Check whether another app is already using the VPN. If Wi-Fi works but cellular doesn't, check the app's cellular data permission before changing your subscription or policies.
Check your system type under Settings > System > About, then compare it with the architectures listed on the download page. After installation, test the system proxy in a browser first. If the client says a local port is already in use, check whether an old client is still running in the system tray. Don't delete your configuration or switch to global mode without checking. Archived versions are mainly useful for reviewing older configurations.
Choose an installer that matches your system architecture and the client's requirements. The first time you connect, the system may ask permission to establish a VPN. If the connection drops when the app goes into the background, check whether the system restricts background activity or battery usage, then review the logs. On devices with work profiles or a system-managed VPN, confirm what is supported rather than assuming one switch will cover every profile.
For desktop Linux, filter by distribution and processor architecture. On Debian or Ubuntu, look for a matching .deb; on Fedora, check for a compatible .rpm. For servers and routers, see the core builds separately. The core has no desktop interface and doesn't configure system permissions, network routes, or startup behavior for you.
Make only the changes you need for your first connection. Check the active configuration, enable one way to capture traffic, then verify the result. Wait until everything works before enabling automatic updates, launch at startup, or on-demand connections. That makes it easier to return to a known-good setup if something goes wrong.
Import and activate a configuration
Open the client's Profiles or Subscriptions page. Import a remote configuration from a URL or choose a local YAML file. After importing, select the profile and confirm it's active. If loading fails, first check that the subscription URL is complete and the returned content uses a supported format. Don't post a private subscription URL in a public support forum.
Choose rule mode and connect
Set the outbound mode to Rule, then check that the proxy groups referenced in the configuration are available. On Mac, you can start by enabling Set as system proxy. On iPhone, connect from the app and approve the prompt to add a VPN configuration. If you used another client before, disconnect it before testing the current one. Don't enable traffic capture in two clients at the same time.
Check the result with a new connection
Open a site expected to connect directly, then one expected to use a proxy group. Compare the results in the Connections list or logs. A page loading only confirms that the request got a response; it doesn't prove the traffic took the intended route. If neither request appears, check how traffic enters the client. If both appear but use the wrong policy, check rule order and proxy group selection.
The Clash ecosystem and the mihomo open-source core
This site brings together download links and guides for multiple projects; it isn't the official release page for a single app. When checking a software's source, look at its client name, platform, and maintenance status. A name containing Clash doesn't mean it's maintained by the same team as other Clash clients.
From Clash configurations to mihomo
Clash introduced a widely used configuration format for rule-based proxies: proxies define connection methods, proxy groups organize candidate routes, and rules determine which policy handles each request. mihomo continues the development and configuration model of Clash.Meta, adding further networking features. Whether an older configuration still works depends on its use of changed fields, rule sets, or client-specific extensions. Keep the original and test a copy in the new client.
Clients and cores are maintained separately
The core parses configurations, handles protocol connections, and matches rules. Desktop clients manage the menu bar or system tray, system proxy, and subscriptions; mobile clients also work with the system VPN interface. Even two clients using the same core family may differ in settings, permission prompts, automatic updates, and error messages. When following another client's guide, you can apply the same rule concepts, but don't assume the interface steps are identical.
Check upstream records when troubleshooting
mihomo source code is released under the GPL-3.0 license. Commits, release notes, and issue discussions in the public repository can help confirm feature changes—there's no need to rely on secondhand claims. Before filing an issue, see if you can reproduce it with a minimal configuration, then record your operating system, client, steps to reproduce, and relevant logs. Remove subscription query parameters, credentials, and private domains. For interface or installation issues, check the relevant client's documentation first.
Check three layers before updating
Updating a client can change its interface, permissions, or bundled core. Updating a subscription changes the remote configuration; refreshing a rule set can change how an individual domain is matched. Avoid changing all three at once. Save your current configuration and key proxy group selections, change one layer at a time, then test both direct and proxied connections again. If the client fails to start after an update, temporarily switch back to a verified copy of your configuration and investigate the first clear error.
Get the core source code
Developers can run the command below in a terminal with Git installed to inspect the source, license, and commit history. It only clones the repository; it doesn't install a client or change system proxy settings.
Does enabling the system proxy send traffic from every app through the proxy?
No. Rules can only match traffic that reaches the client. Some apps use their own network settings and ignore the system proxy. Reproduce the issue first, then decide whether to test TUN mode. See the glossary for related concepts.
Global mode works, but webpages won't load in rule mode. What should I check first?
First, check which rule matched the request and whether an earlier rule sent it to Direct or another proxy group. Then check whether the selected group has an available route. Working in global mode doesn't prove that rule mode chose the same route.
Why did my custom rules disappear after updating a subscription?
If you edit a remote configuration directly, the next download may replace the entire file. To keep your changes, save a local copy or add them to an override layer supported by the client. If you still need remote updates, check the client's override options before choosing the latter.
Does launching the client at startup mean the proxy will connect automatically?
Not necessarily. Launch at startup only means the system will try to open the app. Whether the system proxy or TUN mode is restored automatically depends on the client settings and system permissions. After restarting, check that the app is running, then verify a new request in the Connections list.
If you see a permission prompt during installation, start with the instructions for your platform. Once your configuration works, you can explore switching between subscriptions and automatic updates. The articles below are listed by publication date and can each be read on their own.
Configuration
What Is a Clash Profile? Managing Multiple Subscriptions, Auto-Updates, and Local Configurations
Learn the difference between a remote subscription, a local file, and the active configuration. When keeping multiple profiles, give them clear names, then decide which ones should update on a schedule and which should hold your custom rules.
How to Install a Clash Client on iPhone: App Store Region, Subscription Setup, and Configuration Import
From finding the app in the store to adding your first VPN configuration and importing a subscription by URL, learn which steps are handled by the app and which by iOS—and how to confirm the imported profile is active.
10 Common Clash Questions: Subscription Links, Rule Mode, and System Proxy Explained
Understand subscription setup, traffic capture, and outbound routing as separate steps. If some apps don't use the proxy, identify which layer is causing the issue, then follow the article to find the relevant settings.