Setup Guide · First Connection

Clash Setup Guide

Import a subscription, select Rule mode, route app traffic through the client, and check the resulting connection.

Get a Clash-compatible subscription URL from a trusted source, or download a YAML configuration file. Before you begin, make sure you can open a familiar website on your current network and note it down for comparison. If another proxy or VPN is already configured on your device, record its settings first. On a managed device, follow your administrator’s instructions and don’t overwrite existing work network settings.

STEP 01 / PROFILE

Import a Subscription and Activate the Configuration

Open the client and go to Profiles, Subscriptions, or Configuration in the sidebar or bottom navigation. Choose New, Add, or the plus button, then select the option to import from a URL. Paste the full subscription URL from your provider, add a name to identify its source if needed, then save, download, or import it. The URL may include access credentials, so copy the entire link and don’t share it in group chats or public screenshots. A service login page, purchase page, or QR code image URL is not a subscription URL.

Wait for the new entry to appear in the profile list without any download or parsing errors. Select it, or use its menu to choose Use or Enable. Some versions activate an imported profile automatically; others only add it to the list. Return to the home screen and check the active profile name, then open Proxies or Policy Groups to confirm the client loaded the matching content—not a default profile left over from before. If your provider supplied a local file, choose Import from file in the same menu, select the YAML file, and activate it as well.

Handle Download and Parsing Errors Separately

If the client reports a timeout or connection failure, first check that your network is working, then try refreshing once. If it says access is denied, check with your provider that the subscription is still valid. If the download completes but the content format is invalid, make sure you chose a Clash-compatible format rather than a generic link for another client. The response may also be a login or error page. Don’t keep switching proxy modes—the profile hasn’t loaded yet. If you already have a working profile, keep it until the new one passes verification.

You’re ready to move on when the client shows the expected active profile and the proxy page displays its contents. System traffic usually isn’t going through the client yet. Next, choose how to handle that traffic once it’s connected.

STEP 02 / MODE

Choose a Proxy Mode

Return to the home screen, or open the mode selector at the top of the Proxies page, and choose Rule or Rule. Rule mode checks conditions in the order defined by the configuration, then handles each connection according to the matching rule: some connect directly, some go through a policy group, and others may be rejected. Start with Rule mode so you can compare a connection log against the configuration. After switching, make sure Rule is selected. Seeing multiple modes in the list doesn’t mean they’re all active.

Global and Direct are two other ways to handle traffic. Global mode bypasses rule-by-rule routing and sends traffic connected to the client through the global proxy. Apps that aren’t connected to the client won’t be routed through it just because you switched to Global. Direct mode sends that traffic without an upstream proxy, but it doesn’t turn off the system proxy or your mobile VPN. To restore your device’s original network state, disconnect using the method you enabled in the verification steps.

Check the Policy Group’s Current Route

On the Proxies page, expand any policy group that might handle your test request. For a manual selection group, choose a node you know works so you can compare the result against your selection. For an automatic group, check which member is currently selected; there’s no need to change members one by one just for testing. Group names are set by the configuration author—a group called Auto or Default doesn’t tell you which route it’s using. If its current member is DIRECT, requests handled by that group still connect directly.

If the expected policy group isn’t on the Proxies page, return to the profile list and check which profile is active. Some configurations specify routes directly in their rules, so the absence of a policy group isn’t necessarily an error. Just note the current profile, mode, and identifiable route for now. You can investigate nested policy groups and rule-set updates after verifying the connection in the Advanced Config guide’s rule sets section.

STEP 03 / CONNECT

Enable the Proxy Connection

Once you’ve selected a profile and mode, route test app requests through the client. For the first verification, use just one connection method so it’s clear whether the system proxy or TUN caused the result. Close any pages playing media or downloading files, and keep one browser window open for testing. The desktop and mobile instructions below are separate paths; follow only the one that applies to your device.

Desktop: System Proxy or a Single App

Turn on System Proxy from the home screen, Settings, or the tray menu, and make sure the toggle stays on. If the client also shows the core status, confirm that it’s running. Then open a browser that uses the system network settings. The system proxy only applies to apps that follow those settings; some apps have their own proxy configuration. In some Linux desktop environments, the client may not be able to update system settings. For an initial test, use an app that lets you enter proxy settings manually.

For manual setup, find the listening address and port in the client. If it indicates that a local mixed port is available, choose the HTTP or SOCKS5 type supported by your test app and enter the corresponding local address and actual port. 7890 is a common example, not a value to assume. Don’t enter the external control port as the app’s proxy port. If the toggle turns itself off or reports that the port is in use, check the client’s error message and see whether another instance is already listening. Don’t keep changing browser settings to work around a startup problem.

Mobile: Connect and Approve the System Prompt

On the client’s home screen, tap Connect or turn on the connection toggle. When the system prompt appears for the first time, make sure the request is from the client you just installed and opened, then allow it to add or start a VPN configuration. Return to the app and confirm it’s connected, then check the system settings for the active VPN. Status bar icons vary across operating systems and devices. If you’re told that another VPN is already active, check what it’s used for before deciding whether to disconnect it. If device management policies block the connection, stop here and don’t change device management settings.

A toggle that stays on only means the connection has started. It doesn’t prove that the target app is using the client or that the selected proxy node can connect. Keep the current profile and mode unchanged, then make a new request to verify the actual route.

STEP 04 / VERIFY

Verify the Connection and Routing

Open the client’s Connections or Logs page, switch back to your browser, and visit the familiar website you noted earlier. Make a fresh request rather than returning to an already open tab; a cached page may not generate any network traffic. Switch back to the client right away and look for the corresponding entry by time or domain. Some connections close quickly and appear only in the logs. If a page requests multiple domains, look for the main domain in the address bar rather than treating an image or script domain as the test target.

Once you find the entry, check the destination domain, matched rule, and final route. If a request expected to connect directly shows DIRECT, it reached the client and was routed directly by the rule—this is different from the request never reaching the client. To verify a proxy route, choose an accessible site that should use a proxy under the current configuration, then check that the entry points to the expected policy group and node. A page loading, a VPN icon, or a speed test result alone doesn’t confirm which route the browser request took.

Narrow Down the Issue Based on the Logs

If there’s no entry for the test request, return to the connection steps and check that the system proxy, per-app proxy, or VPN is still enabled, and that the test app is actually using it. If there is an entry but it uses the wrong route, go back to the profile and mode, then check the current rules and policy group member—don’t change ports yet. If the expected proxy is selected but requests keep timing out, choose another known-working node in the same group and test the same destination again, changing only one setting at a time. If you see a certificate warning, don’t bypass it. Stop testing and check the system time, client logs, and network environment.

Record the test domain, matched rule, and actual route. If they match the expected path, your first connection check is complete. If this was only a trial, turn off System Proxy in the desktop client; if you configured an individual app, undo that setting there too. On mobile, tap Disconnect, then check in system settings that the VPN has stopped. Finally, reopen the website you used for comparison and confirm your normal network is back. Once you can reproduce the first connection and have a specific need to change traffic routing or DNS behavior, see the Advanced Config guide for TUN, DNS, and Fake-IP settings.