Clash Logo
clash-meta.org
Mihomo Kernel Client Aggregation and Tutorial Center
Homepage Download Tutorial Frequently Asked Questions GitHub
Tutorial Center · Client Installation · Subscription Import · Agent Enablement · Troubleshooting

Mihomo client Complete tutorial on installation, configuration and use

This tutorial explains in detail the installation, configuration and usage process of Mihomo eco-related clients, covering the entire process including download preparation, subscription import, node selection, agent activation, rule distribution, TUN mode configuration and troubleshooting of common problems.

Applicable to Windows / macOS / Linux / Android Cover common usage scenarios Contains practical code examples
The client itself does not contain nodes and requires a subscription to connect to the Internet. No node? Signing up for this high-speed airport will give you 1GB of Hong Kong high-speed experience traffic, which is valid within 24 hours. You can try the speed first after importing it; buy if it suits you. Alipay pays directly. It also supports cryptocurrency payment. No cards are tied and no real-name records are left.
Get high-speed node
Tutorial Overview

Usage process overview

The complete process of using the Clash client can be divided into four stages: preparation stage (downloading the client, obtaining subscriptions), installation stage (granting system permissions), configuration stage (importing subscriptions, selecting nodes), and usage stage (enabling proxy, verifying connection). The tutorial unfolds in this order.

1
Prepare

Download the corresponding platform client and obtain the subscription link from the airport

2
Install

Complete the client installation and grant necessary system permissions

3
Configuration

Import subscription configuration and select available nodes

4
Use

Enable the agent and verify the network connection status

First step

Preparation before installation

Before starting the installation, you need to confirm your system platform, select the appropriate client version, and prepare the subscription link (usually provided by the airport service provider).

Confirm system platform and architecture
Windows:Press Win + R to enter winver, or right-click "This PC" → Properties. Most PCs are x64 (Intel/AMD); Snapdragon laptops are arm64.
macOS:Click the Apple icon → About This Mac. When displaying M1/M2/M3/M4, select aarch64 (arm64); when displaying Intel, select x64; for the Universal version, both can be used.
Linux:Terminal Execution uname -m. For x86_64, choose the amd64 package; for aarch64, choose the arm64 package. Ubuntu/Debian uses .deb; Fedora/CentOS uses .rpm.
Android:View with CPU-Z or AIDA64 App. After 2020, mobile phones will basically be arm64-v8a; old devices may be armeabi-v7a; emulators may be x86_64.
Select and download the client

Recommended client:Clash Verge Rev is preferred on desktop (Tauri architecture, low memory footprint); Android preferred FlClash(Designed by Material You, consistent cross-platform experience).

Download tips: Go to Download Center Get the latest version. All links point to the official GitHub Release page, which is pure and safe.
Prepare subscription link

The subscription link is usually provided by the airport (agent service provider), with a similar format https://example.com/subscribe?token=xxxxx. Log in to the airport backend, find the "Subscription" or "Clash Subscription" tab, and copy the link for later use.

Safety tips: The subscription link contains all your node information and is private data. Do not share it with others. If you find a leak, please reset the subscription link immediately in the airport backend.
Second step

Complete tutorial on desktop

Take Clash Verge Rev as an example, available for Windows, macOS and Linux. The operation logic of other clients (such as FlClash, Mihomo Party) is basically the same.

1
Install the client
Bypass the system security prompts and complete the installation
Windows Installation:

Double-click the .exe or .msi installation package. The first time you run it, a "Microsoft Defender SmartScreen Blocked..." prompt will pop up. This is because the open source software has not purchased a paid digital signature.

Solution:
  1. Click in the prompt window"More information"
  2. Click on the appearing "Run anyway"Button
  3. Complete the installation according to the installation wizard
macOS installation:

Double-click the .dmg file and drag the application icon to the Applications folder. When opening the prompt "Unable to verify developer" for the first time:

Solution:
  1. Go toSystem Settings → Privacy and Security
  2. Scroll down to the bottom and find the blocked application prompt
  3. Click"Open anyway"And enter the password
If you enable TUN mode, you need to additionally allow system extensions to load
Linux Installation:
# Debian / Ubuntu system
sudo dpkg -i clash-verge-rev_*.deb

# Fedora / CentOS / RHEL system
sudo rpm -i clash-verge-rev-*.rpm

# AppImage (universal format, installation-free)
chmod +x Clash.Verge_*.AppImage
./Clash.Verge_*.AppImage

If prompted that webkit2gtk is missing, execute:sudo apt install libwebkit2gtk-4.1-0

2
Import subscription configuration
Import airport subscription from URL
Detailed steps:
  1. Open the Clash Verge Rev client
  2. Click on the left navigation bar"Configure"(Profiles) Tag
  3. Click on the upper right corner"New"button or "+" Icon
  4. Select"Import from URL"(Import from URL)
  5. Paste your subscription link in the pop-up window
  6. (Optional) Give the configuration a name, such as "Airport A"
  7. Click"Save"or"Import"
  8. Wait for the download to complete, and the new configuration will appear in the configuration list
  9. Right-click the configuration → select"Enable" (or click to activate)
Important tip: close the proxy before importing

Before updating your subscription, be sureTurn off the client's "system agent" switch. If the proxy is turned on to update the subscription, an infinite loop will be formed (the subscription request itself also tries to go through the proxy), resulting in Download Error.

Subscribe automatic update settings

Right-click configuration → select"Automatic update"Or turn on "Automatic update subscription" in the settings. The recommended interval is 24 hours to ensure that node information is refreshed in time.

3
Select agent node
Measure speed and select nodes with low latency
Operation steps:
  1. Click on the left"Agent"(Proxies) label
  2. Click"All delayed tests"Icon (lightning sign)
  3. Wait for the speed test to be completed, the delay value will be displayed next to the node name
  4. Choose nodes with low latency (usually < 300ms) and stable
  5. Click on the node to make it selected (usually highlighted)
Speed test description

Get started with Clash Verge Rev v2.4.7Real TLS handshake delayReplacing HTTP request delay, the speed measurement is more accurate. Latency only represents handshake speed, not actual bandwidth.

Delay reference:< 100ms is extremely fast; 100-300ms is normal; > 500ms is slow or unstable.

Agent group description

If the configuration file contains proxy groups (Proxy Groups), you will see multiple groups, common types:

  • Select (manual selection): Manually click to select the node
  • URLTest (automatic selection): Automatically select the node with the lowest latency
  • Fallback (failover):Automatically switch to the backup node when the primary node fails
  • LoadBalance (load balancing):Multi-node offloading
4
Enable system proxy
Turn on the proxy switch and verify the connection
Enable method:
  1. Return to clientHomepageorSettingsPage
  2. Find"System agent"(System Proxy) switch
  3. Turn on the switch (usually turns green or highlighted)
  4. At this time, the system traffic will pass through the Clash proxy
Verify whether the proxy is effective
  1. Open the browser and visit ip.sb or ipinfo.io
  2. Check whether the displayed IP address is the IP of the proxy node
  3. Check whether the geographical location is the country/region where the node is located
  4. If the IP is still a local IP, check whether the proxy switch is really turned on
Proxy mode description

Clash usually provides three modes, which can be switched on the client homepage or settings:

  • Rule (rule):Diversion according to rules, domestic direct connection, foreign proxy (recommended for daily use)
  • Global (global):All traffic goes through the proxy, suitable for testing node connectivity
  • Direct (direct connection):All traffic does not go through the proxy, which is equivalent to turning off the proxy
Third step

Android complete tutorial

For the Android platform, it is recommended to use FlClash (designed by Material You) or Clash Meta for Android (more comprehensive functions). The following takes FlClash as an example.

1
Install APK
Allow applications from unknown sources
Installation steps:
  1. Download the APK file of the corresponding architecture (most mobile phones choose arm64-v8a)
  2. Click the APK file to install
  3. If prompted "Applications from this source are not trusted", clickSettings
  4. Open on jump page"Allow installation of unknown applications"Switch
  5. Return to continue the installation and open the application after completion
Mobile phone settings paths of different brands
  • Xiaomi MIUI: Settings → Application settings → Application management → Three dots in the upper right corner → Install unknown application
  • Huawei EMUI:Settings → Security → More security settings → Install external source applications
  • OPPO ColorOS:Settings → Application Management → Three dots in the upper right corner → Special application permissions → Install unknown applications
  • Native Android:Settings → Apps and Notifications → Special App Permissions → Install Unknown Apps
2
Import subscription
Add configuration link
FlClash import method:
  1. Open FlClash App
  2. Click on the bottom"Configure"(Profiles) Tag
  3. Click on the lower right corner"+"Floating button
  4. Select"Add from URL"
  5. Paste the subscription link and click"OK"
  6. Wait for synchronization to complete (usually a few seconds)
  7. Click the configuration to activate it (there will be a check mark)
WebDAV Data Sync (optional)

FlClash supports WebDAV synchronization configuration to multiple devices. Configure a WebDAV server (Nut Cloud, Nextcloud, etc.) in settings to synchronize subscriptions and node selections across devices.

3
Enable VPN And test
Authorize VPN permissions and select the node
Operation steps:
  1. Click on the bottom"Agent"(Proxies) label
  2. Select an available node (you can click the speed test icon to check the delay first)
  3. Return"Home"Label
  4. Click on the large Start buttonorConnection switch
  5. The first connection will pop up"Connection request"Tips
  6. Check"I trust this app", click "OK"
  7. The VPN icon appears in the notification bar, indicating that the proxy is enabled
  8. Open the browser and visit ip.sb to verify whether the IP has changed
Separate application proxy (optional)

FlClash and Clash Meta for Android support sub-application proxies. You can choose from the settings:

  • Only allow mode:Only the checked App uses the proxy, and other direct connections
  • Only deny mode:Checked Apps do not use proxies (such as games, banking apps), others use proxies
Configure and enable

General operations after import

Whether using desktop or Android After completing the subscription import, the client usually needs to go through three steps of node selection, agent activation and rule verification before it can enter the regular use state.

Node selection

It is recommended to manually select a known available node for testing. It is not recommended to directly determine client exceptions without verifying node availability. Use the latency testing feature to filter for low latency nodes.

Agent activation

System proxy or TUN is usually enabled on desktop; VPN connection is usually enabled on Android. If permissions are not granted (such as Windows administrator permissions, macOS system extensions, Android VPN authorization), the proxy capability may not take effect.

Access verification

It is recommended to open common web pages (such as Google, YouTube) for basic testing. Then switch rule mode, global mode or other configurations as needed to observe whether the access results are as expected.

Advanced configuration

TUN Mode, Rule Diversion and DNS Optimization

For users with advanced needs, you can enable TUN mode to globally take over traffic, customize rule distribution, and optimize DNS configuration to prevent pollution.

TUN virtual network card mode

Function:Create a virtual network card to take over all traffic of the device (including UDP) and solve the problem of command line tools (Git, npm, Docker), games and UWP applications not using the system proxy.

Opening method:
  • Clash Verge Rev:Settings → TUN mode → Turn on the switch
  • Windows:You need to run the client as an administrator
  • macOS:For the first time, you need to allow system expansion in System Settings → Privacy and Security
  • Linux:Requires root permissions or CAP_NET_ADMIN capability
TUN mode considerations
  • TUN mode and system agent can be turned on at the same time without conflicting with each other
  • After opening, some games may detect the virtual network card and refuse to run
  • If you encounter network abnormalities, you can try to turn off TUN to troubleshoot problems
Rule distribution instructions

Clash's rules determine which traffic goes through the proxy and which traffic is directly connected. Common rule types:

Rule matching priority (from top to bottom):
  1. DOMAIN (precise domain name):DOMAIN,google.com,Proxy - google.com Go through proxy
  2. DOMAIN-SUFFIX (domain name suffix):DOMAIN-SUFFIX,google.com,Proxy - *.google.com full agent
  3. DOMAIN-KEYWORD (keyword):DOMAIN-KEYWORD,google,Proxy - Including google domain name proxy
  4. GEOIP (geographic location):GEOIP,CN,DIRECT - Domestic IP direct connection
  5. IP-CIDR (IP segment):IP-CIDR,192.168.0.0/16,DIRECT - LAN direct connection
  6. MATCH (secure rules):MATCH,Proxy - Other traffic goes through proxy
Custom rules (Clash Verge Rev)

Right-click the subscription configuration → Edit Rules → You can add custom rules in the graphical interface, and the rules will be inserted before the subscription rules. Extension scripts (JavaScript) can also be used to dynamically modify rules.

See the homepage tutorial for detailsExtended configuration and scriptsChapter.

DNS anti-pollution configuration

Properly configuring DNS can prevent operator DNS pollution and ensure accurate domain name resolution. Mihomo supports fake-ip mode (recommended) and redir-host mode.

fake-ip mode description:

Mihomo immediately returns a 198.18.0.0/16 For fake IPs within the range, rule matching is completed at the domain name stage, with lower latency and more accurate diversion.

dns: enable: true ipv6: false enhanced-mode: fake-ip fake-ip-range: 198.18.0.1/16 fake-ip-filter: - "*.lan" - "*.local" # Use domestic DNS to resolve the proxy node domain name proxy-server-nameserver: - https://223.5.5.5/dns-query - 119.29.29.29 # Overseas domain name resolution nameserver: - https://1.1.1.1/dns-query - https://8.8.8.8/dns-query
Configuration instructions
  • proxy-server-nameserver:Specialize in parsing proxy node domain names and use domestic DNS to ensure they are not contaminated
  • nameserver:To resolve overseas domain names, it is recommended to use DoH (DNS over HTTPS)
  • fake-ip-filter:Whitelist, these domain names skip fake-ip (such as LAN domain names)

See the homepage tutorial for detailsDNS anti-pollution configuration details

Troubleshooting

Diagnosis and solutions to common problems

This article summarizes the troubleshooting ideas and solutions for the most common problems encountered during use, such as connection failure, slow speed, and the inability of some applications to connect to the Internet.

Problem 1: Import subscription prompts "Download Error" or timeout

Common reasons:

  • The client turns on the system proxy or TUN mode to update the subscription, forming an infinite loop
  • The subscription link itself is invalid or closed by the airport
  • The current network cannot access the subscriber server (blocked)
  • Firewall intercepts client network requests

Solution:

  1. Turn off the client's system proxy and TUN mode
  2. Click again to update the subscription
  3. Confirm whether the subscription link is correct (whether it is complete when copying)
  4. Contact the airport customer service to confirm whether the subscription is valid
  5. Try to use a mobile hotspot to change the network environment
Problem 2: Still unable to access Google and YouTube after turning on the proxy

Troubleshooting steps:

  1. Confirm that the node is available:Manually switch to other nodes on the proxy page, or click Latency Test
  2. Confirm that the agent is enabled:Check whether the system proxy/VPN switch is really turned on
  3. Confirm the rule mode:In Rule mode, confirm that Google is acting as a proxy (can temporarily switch to Global mode for testing)
  4. Check DNS:Visit ip.sb to see if the IP has changed; if it has not changed, the proxy has not taken effect
  5. Browser cache:Clear the browser cache and cookies and try again
  6. Firewall:Check whether the system firewall blocks the client
Problem 3: Some applications/games cannot connect to the Internet (the proxy is turned on)

Common reasons:

  • This application does not use the system proxy (such as command line tools, some games)
  • Windows UWP applications are restricted by Loopback
  • The application itself detects the proxy/virtual network card and refuses to run

Solution:

  1. Enable TUN mode: Can take over applications that do not use system proxy
  2. UWP Apps (Windows):Use "UWP Loopback tool" in Clash Verge Rev settings to lift restrictions
  3. Command line tool: Manually configure the agent environment variables (see below)
  4. Game refuses to run:Some anti-cheating games detect virtual network cards and need to turn off TUN mode
# Git configuration agent
git config --global http.proxy http://127.0.0.1:7897

# npm configuration agent
npm config set proxy http://127.0.0.1:7897

# Temporary environment variables (Linux/macOS)
export http_proxy=http://127.0.0.1:7897
export https_proxy=http://127.0.0.1:7897
Problem 4: The speed is very slow or dropped frequently

Possible reasons:

  • The node is blocked or speed-limited (airport overbooking)
  • Poor local network environment
  • DNS Pollution leads to resolution to wrong IP
  • Rule configuration problem (the proxy should be used for direct connection)

Optimization method:

  1. Replace the node and choose a low-latency and stable one
  2. Avoid crowded nodes during peak hours (8-11pm)
  3. Use anti-blockade protocols such as Hysteria2 and VLESS
  4. Configure DoH/DoT DNS to prevent pollution
  5. Contact airport customer service to feedback node quality
  6. Consider changing the airport service provider
Problem 5: macOS TUN mode cannot be turned on

Solution steps:

  1. System Settings → Privacy and Security
  2. Scroll down to the bottom and find the "Blocked... System extension" prompt
  3. Click "Allow" and enter the system password
  4. Re-enable TUN mode in the client

If multiple attempts still fail, try to uninstall the service on the terminal and then reinstall it:

APP="/Applications/Clash Verge.app"
sudo "$APP/Contents/Resources/resources/clash-verge-service-uninstall"
sudo "$APP/Contents/Resources/resources/clash-verge-service-install"
Frequently Asked Questions

High-frequency problem solving

Q1: What should I do if there are no nodes after importing subscriptions?

This situation is usually related to invalid subscription, incorrect link filling, current network inability to access the subscription address, or abnormal configuration format. Suggestions: ① Turn off the system proxy and TUN mode and then renew the subscription; ② Confirm whether the subscription link is complete (do not miss characters when copying); ③ Contact the airport customer service to confirm the subscription status; ④ Check the client log for error messages.

Q2: What is the difference between TUN mode and system proxy?

System AgentOnly applications that follow the system proxy settings (such as browsers) can be proxied. Some command line tools (Git, npm, Docker) and games will not be proxied. TUN ModeAll applications can be proxied by creating a virtual network card to take over all traffic (including UDP), but administrator rights are required. Both can be turned on at the same time.

Q3: Why does the administrator rights or system authorization prompt appear?

Some proxy modes require higher system permissions, such as TUN mode (need to create a virtual network card), service mode (resident in the background). Windows requires administrator privileges; macOS requires system extensions; Linux requires root or specific capabilities. These prompts are part of the normal authorization process, and relevant functions can only be used after permission.

Q4: How to choose installation packages for different systems?

Windows:Select x64.exe for x64; select arm64.exe for arm64 (Snapdragon notebook). macOS:For Apple Silicon (M1/M2/M3/M4), choose aarch64.dmg; for Intel, choose x64.dmg; for Universal version, both can be used. Linux: For Ubuntu/Debian, choose .deb; for Fedora/CentOS, choose .rpm; for universal, choose AppImage. Android:For mobile phones after 2020, choose arm64-v8a.apk; for old devices, choose armeabi-v7a.apk; for simulators, choose x86_64.apk.

Q5: Does the Clash client itself provide nodes?

Not available. Clash series clients are pure proxy tools and do not contain any node or server resources. You need to purchase a subscription from the agency service provider (commonly known as "airport"), obtain the subscription link and then import it into the client. When choosing an airport, it is recommended to pay attention to whether it provides new agreements, after-sales support, and whether there is a trial period.

Q6: When should Rule mode and Global mode be used?

Rule (rule) modeIntelligent distribution according to the configuration file: domestic websites are directly connected, foreign websites use proxies, taking into account speed and traffic, Preferred for daily useGlobal (global) modeSend all traffic to the proxy, which is suitable for testing node connectivity or accessing services that require a proxy. Direct (direct connection) modeAll traffic does not go through the proxy, which is equivalent to turning off the proxy.

Q7: How to verify whether the proxy is really effective?

Recommended steps: ① Visit ip.sb or ipinfo.io and check whether the IP is the node IP; ② Access dnsleaktest.com Run Extended Test to check whether DNS leaks; ③ Access browserleaks.com/ip Check if WebRTC leaks real IP. If the IP is still the local IP, it means that the proxy is not effective. Check whether the switch is turned on and whether the node is available.

Q8: Is Clash safe? Will it steal my data?

The full source code of Clash Verge Rev (GPL-3.0 license) and FlClash is publicly available on GitHub and can be reviewed by anyone. The project is maintained by an active community, and PR merging requires review. The software itselfDoes not contain any nodes or behavior of uploading data, just forward traffic to the proxy node according to the configuration file. The real thing to pay attention to is whether the "airport" (proxy service provider) you use is trustworthy, not the client itself.

Still have any problems? Go to the FAQ center to view the complete diagnosis process, root cause analysis and 4-platform differences explanation.
View the complete FAQ center
High-speed airport recommendation Register to receive 1GB trial traffic
No node yet? Sign up and get 1GB of Hong Kong high-speed trial traffic, which is valid for 24 hours. You can connect to it with one click to try the speed, and then buy if it suits you. Alipay allows direct payment and can be activated in a few minutes; if you are more concerned about privacy, it also supports cryptocurrency payments - no bank cards are tied, and no real-name payment records are left.
Get high-speed node