QUICKSTART First-Time Setup

Clash Setup Guide

Import a subscription, choose Rule mode, connect, and verify the traffic route.

With the client installed and a subscription ready, first-time setup usually takes about 10 minutes. Have a subscription link for Clash or mihomo, or a local YAML configuration. If you haven't installed a client yet, choose one for your platform on the downloads page.

Import and Activate a Subscription

Open the client and go to Profiles, Configuration, or Subscriptions. If you have a subscription link, choose Import from URL, paste the full address from your provider, then click Import or Save. Some clients fetch the configuration as soon as you save; others require you to click Update next to the entry. Wait until the profile appears in the list with no download errors before continuing. A regular login page, purchase page, and subscription URL serve different purposes. If the imported response isn't a valid configuration, check your provider's dashboard for the correct export option.

Importing a Local File or Troubleshooting Import Errors

For a local configuration, choose Import from File and select a file with a .yaml or .yml extension. Importing a local file usually loads its contents as they are at that moment; later edits to the original file aren't tracked automatically. The file extension alone doesn't determine the format—renaming an export from another client won't convert its syntax. If you see an unsupported-field or parsing error, first make sure the configuration matches your current core, then check which line or section the client flagged.

If importing from a link fails, first determine whether the issue is downloading or parsing. A timeout means the client couldn't retrieve the content in time. A permissions error means you should check your subscription status and the address you copied. If the content downloaded but triggered a syntax error, check the export format. Subscription URLs may contain access credentials, so don't post the full link in a public discussion or submit it to an online converter just to test it. When contacting your provider, the error type and time it occurred are usually more useful.

Confirm the Active Configuration

Return to the list, select the newly imported entry, and choose an action such as Enable or Apply. Make sure the active indicator moves to that entry. A successful import means the client saved the configuration; it doesn't confirm that the core is using it. If you have an older configuration on the device, keep it for now and give the new entry a distinctive name to avoid updating the wrong one later. Next, open the Proxies page and check that the policy groups match the new configuration. If the list still shows old content, return to the Profiles page and check whether the configuration was applied. If the client says the core isn't running, start by checking its startup message.

Before you continue: The new entry is active, and its policy groups are visible on the Proxies page.

Choose a Proxy Mode

On the Proxies page, open the mode selector and choose “Rule” or Rule. In Rule mode, traffic follows the configured rules in order: it may connect directly, go through a proxy group, or be rejected. Global mode generally sends traffic handled by the core to the global policy, while Direct mode connects it without a proxy. For your first setup, use Rule mode so you can verify both a direct connection and a proxied route.

Find the Policy Group Handling the Traffic

The mode and policy group are separate settings. The mode determines whether traffic is routed by rules; the policy group determines which outbound route to use after a rule matches. For example, if a rule points to a group named PROXY, check that group's current selection—not a node in some other group. Group names come from the configuration, and clients may display localized names or another group as an option. If you can't tell which group a rule uses, check the rule's policy name in the configuration preview or rule view, then find the matching group on the Proxies page.

If you can change the policy group's selection manually, choose an available node from your subscription and note the group name and selected route for comparison in Step 4. If the group automatically selects a route based on test results, leave its default selection in place and use the actual outbound route shown in the connection details for verification. A successful node test only means the test address was reachable at that time; it doesn't guarantee every site will load. Likewise, a single timeout doesn't mean the configuration is broken. First check whether the test address and the address you're visiting are the same.

Choose Two Requests You Can Tell Apart

Before connecting, choose two domains you can normally access from the current configuration: one that should go direct and another that should use the policy group you just checked. Check the route against the configured rules; a specific domain rule may take precedence over a general rule later in the list. If the configuration has no direct rule you can use for comparison, verify the routes it does provide—there's no need to edit rules just for this test. If policy groups and rule matching are unfamiliar, see the entries for Proxy Mode and Rules and Routing in the glossary.

Before you continue: Rule mode is selected, and you know the expected route for at least one test domain.

Connect

Loading a configuration and selecting a node doesn't mean your apps' requests are going through the client. Next, enable the traffic entry point for your device. For the initial test, use just one connection method. Changing the system proxy, TUN, and an in-app proxy at the same time makes it harder to tell which setting affected the result. Note your existing settings before making changes. If your device is managed by your employer or school, follow its network requirements.

Desktop: Enable the System Proxy

Find System Proxy in the client's Settings or tray menu and turn it on. Return to the client to make sure it stays enabled, then open a browser that normally follows the system proxy. If the switch turns itself off immediately, check whether the client reported a failure to update system settings or another proxy app is controlling the same setting. Desktop environments and apps on Linux vary in their system proxy support. If the setting isn't available or an app clearly ignores system settings, check the current client documentation for supported connection methods.

A browser may ignore the system proxy if it has its own proxy settings, uses a dedicated extension to manage network traffic, or is configured by an organization policy. For testing, use a browser with clear settings that follows the system proxy. Don't keep switching Clash's rule mode to fix a browser connection issue. Enabling the system proxy doesn't route traffic from every app. To route other apps, read the TUN setup guide and check whether TUN is appropriate for your setup.

Mobile: Approve the System Connection

Return to the client's home screen and tap Connect or the start button. The first time you connect, the system will usually ask to add a VPN configuration or establish a connection. Make sure the request comes from the client you just opened, then approve it as prompted. Back in the client, check that the status changes from disconnected to connected. A VPN status indicator only confirms that the system accepted this connection method; it doesn't show that all requests are using a proxy route. Check the actual routing in Step 4.

If the mobile client quickly returns to a disconnected state, first check for a configuration load error, then see whether another VPN is using the system connection. If all pages suddenly stop loading on desktop, turn off the system proxy you just enabled and check whether your original connection works again. Then check the active configuration and policy group. Restoring a working connection before troubleshooting each setting is more likely to reveal the cause than repeatedly importing the same subscription.

Before you continue: The system proxy is enabled on desktop, or the mobile client shows a successful connection. Make a new browser request now.

Verify the Connection

Keep the client's Connections view open and visit a domain you picked in Step 2 in a new browser session. If possible, close the previous session first to reduce the chance of reusing an old connection. If the page may be cached, choose one that will definitely make a network request. A page often loads resources from other domains, such as images and scripts. When checking the result, focus on the main domain in the address bar and the time of the request so you don't mistake a background request for your test.

Compare the Rule and the Actual Route

In the Connections view, find the request by domain and expand its details to see the rule, policy group, or outbound route reported by the client. Compare this with what you expected in Step 2: a direct connection should show DIRECT or an equivalent label; a request routed through a proxy group should show the expected group or final node. Short-lived requests may finish before you switch back to the client. Watch the connection list as you visit the domain, or check the entry in the client's existing logs. Base your check on the actual outbound information, not just whether the page loads.

If you use an IP lookup site as an extra check, it only shows where that lookup site went for that request. Another domain on the same device may match a different rule, and an unchanged IP address may simply mean the lookup site was configured to go direct. Once you've confirmed that a request entered the core and followed the expected route, test the other domain you selected. After switching nodes, make a new request the same way; existing connections may not switch with the selection.

Use What You See to Find the Problem

If the new request never appears in the Connections view or logs, return to Step 3 and check whether the app is using the right connection method. If the request appears but takes the wrong route, return to Step 2, confirm the selected mode, and check whether an earlier rule matched first. If the route is correct but the page won't load, try another available node in the same policy group and test the same domain again. Change one thing at a time so you can tell what made a difference. If the browser reports an untrusted certificate, don't ignore the warning and continue. Check your system clock and the certificate details first, then see the troubleshooting section in the FAQ.

You're done when: You can find the request in the Connections view or logs, and its actual route matches the configuration. When you're finished, turn off the system proxy or disconnect the mobile client if you don't need to stay connected.