- Home
- Knowlebge base
- split tunneling in HAPP
Setting up split tunneling in the HAPP client

📑 Table of Contents
- Introduction
- What is split tunneling?
- Step 1. How HAPP handles traffic
- Step 2. Split tunneling setup examples
- Scenario 1. All internet through VPN, except Russian sites and IPs
- Scenario 2. All internet direct, except blocked large services
- Scenario 3. All internet direct, except chosen websites
- Scenario 4. All internet direct, except chosen apps
- Scenario 5. Discord through VPN, game direct
- Scenario 6. Local network direct
- Scenario 7. Different sites through different VPN locations
- FAQ
Introduction
Split tunneling lets you divide your internet traffic. You choose what goes through the VPN and what goes directly through your normal connection. HAPP stays running, and the traffic is separated automatically.
What is split tunneling?
Split tunneling is a feature that lets you send only part of your traffic through the VPN.
This is useful when you want to:
- 🌐 Open blocked websites or services through VPN
- 🏠 Keep local websites working directly
- 📱 Use VPN only for selected apps
- 🎮 Lower delays in games while keeping chat apps on VPN
Step 1. How HAPP handles traffic
HAPP uses the Xray core and flexible routing rules to manage traffic. In simple words, you create rules, and HAPP checks them one by one from top to bottom. As soon as one rule matches, HAPP applies that action and stops checking the rest.
⚠️ Rule order is very important. HAPP reads rules from top to bottom and stops at the first match.
What is a rule?
A rule has three parts:
- Type — What HAPP checks. For example IP, domain, or app name.
- Value — The thing you want to match. For example
youtubeorru. - Action — What HAPP should do with that traffic.
Possible actions:
- 🟢 PROXY — send traffic through VPN
- 🔵 DIRECT — send traffic outside VPN
- 🔴 BLOCK — block the connection
Rule types in HAPP
- DOMAIN / DOMAIN-SUFFIX — For a specific site, such as
example.com - GEOSITE — For a large service with many domains, such as YouTube
- GEOIP — For IP ranges of a country, such as
ru - PROCESS-NAME — For a desktop app, such as
Discord.exe - Per-App Proxy — For choosing apps on a phone
What are GeoIP and GeoSite?
You do not need to add thousands of IPs or domains by hand. HAPP uses built-in databases and updates them automatically.
- GeoIP groups IP ranges by country or service
- GeoSite groups domains for large services that use many hidden technical domains
💡 Tip: Use GEOSITE for large platforms. Use DOMAIN for small websites.
Step 2. Split tunneling setup examples
Open HAPP and go to: Settings → Routing rules
Scenario 1. All internet through VPN, except Russian sites and IPs
This setup is useful when you want to keep VPN on all the time, but still open Russian websites or apps directly.
🛠️ Steps:
- Open routing rules
- Press
+to add a new rule block - Move this block to the top
- Add these conditions:
- Type:
GEOIP→ Value:ru - Type:
GEOSITE→ Value:ru
- Type:
- Set the action for this block to DIRECT
- Make sure the default rule is PROXY
- Save
✅ Result:
- Russian sites and IPs → direct
- Everything else → VPN
Scenario 2. All internet direct, except blocked large services
This is useful when you want to use VPN only for services like YouTube, Instagram, or Netflix.
🛠️ Steps:
- Set the default rule to DIRECT
- Press
+to create a new rule block - Move it to the top
- Add GEOSITE rules such as:
youtube,instagram,netflix - Set the action for this block to PROXY
- Save
✅ Result:
- Most internet → direct
- Selected blocked services → VPN
Scenario 3. All internet direct, except chosen websites
This works well when you only need VPN for a few websites.
🛠️ Steps:
- Set the default rule to DIRECT
- Create a new rule block above the others
- Add the websites you need with type DOMAIN — for example
chatgpt.com,x.com - Set the action to PROXY
- Save
✅ Result:
- Only chosen websites → VPN
- Everything else → direct
Scenario 4. All internet direct, except chosen apps
📱 On iPhone or Android
You can use Per-App Proxy on mobile devices. Choose whether only selected apps go through VPN, or the opposite, and then mark the apps you want.
- Open Per-App Proxy
- Choose the mode: only selected apps go through VPN, or the opposite
- Select the apps
- Save if needed
💻 On Windows, macOS, or Linux
- Open routing rules
- Add a rule with type PROCESS-NAME
- Enter the exact app file name — for example
telegram.exe - Set the action to PROXY
- Keep the default action as DIRECT
✅ Result:
- Only selected apps → VPN
- Other traffic → direct
Scenario 5. Discord through VPN, game direct
This setup is useful when you want voice chat through VPN, but want lower ping in the game itself.
🛠️ Steps:
- Create a rule block for Discord:
- Type:
PROCESS-NAME→ Value:Discord.exe→ Action: PROXY
- Type:
- Move this block to the top
- Create a rule block for the game:
- Type:
PROCESS-NAME→ Value:EscapeFromTarkov.exe - Add launcher too if needed:
BsgLauncher.exe - Action: DIRECT
- Type:
- Save
✅ Result:
- Discord → VPN
- Game → direct connection (lower ping)
Scenario 6. Local network direct
Use this if you want to keep access to your router, printer, or smart home devices while VPN is on.
🛠️ Steps:
- Open Settings
- Turn on Bypass system proxy for local addresses
- Save if needed
✅ Result:
- Local devices stay reachable directly
- VPN does not break access to your home network
Scenario 7. Different sites through different VPN locations
⚙️ This is an advanced setup.
If you want Site A through one VPN server and Site B through another, the normal basic rules are not enough.
What to do:
- Use advanced JSON routing profiles
- Import them into HAPP
- Prepare separate outbound connections for each route
FAQ
❓ I added a site with DOMAIN, but videos or images do not load
Many services use extra hidden domains for video, images, or content delivery. Replace a simple DOMAIN rule with a GEOSITE rule for that service.
❓ I set up rules, but the traffic still goes the wrong way
Check rule order first. HAPP reads rules from top to bottom. If a broad rule is above a specific rule, the lower rule may never be used.
❓ I lost access to local devices
Make sure Bypass system proxy for local addresses is enabled in Settings.
📌 Final notes
Start with a simple setup first:
- Default DIRECT — if you want VPN only for a few apps or sites
- Default PROXY — if you want almost everything through VPN
Then add your exceptions above the default rule.
⚠️ Rule order decides everything.
