Convert Figma logo to code with AI

2dust logov2rayNG

A V2Ray client for Android, support Xray core and v2fly core

62,646
8,103
62,646
47

Top Related Projects

A platform for building proxies to bypass network restrictions.

113,831

A GUI client for Windows, Linux and macOS, support Xray and sing-box and others

A shadowsocks client for Android

19,750

An unidentifiable mechanism that helps you bypass GFW.

Quick Overview

v2rayNG is an Android client for V2Ray, a platform for building proxies to bypass network restrictions. It provides a user-friendly interface for configuring and managing V2Ray connections on Android devices, allowing users to access blocked content and enhance their online privacy.

Pros

  • Easy-to-use interface for managing V2Ray configurations
  • Supports multiple protocols and encryption methods
  • Regular updates and active community support
  • Open-source, allowing for transparency and community contributions

Cons

  • May require technical knowledge to set up and configure properly
  • Performance can vary depending on the server and network conditions
  • Limited documentation for advanced features
  • Potential legal concerns in some jurisdictions regarding VPN usage

Getting Started

To get started with v2rayNG:

  1. Download the latest APK from the releases page on GitHub.
  2. Install the APK on your Android device.
  3. Open the app and tap the "+" button to add a new server configuration.
  4. Enter the server details manually or import a configuration file.
  5. Select the newly added server and tap the "V" button to connect.

For more detailed instructions and advanced usage, refer to the project's wiki on GitHub.

Competitor Comparisons

A platform for building proxies to bypass network restrictions.

Pros of v2ray-core

  • Core functionality and protocol implementation
  • More extensive documentation and community support
  • Better performance and resource efficiency

Cons of v2ray-core

  • Lacks a user-friendly GUI
  • Requires more technical knowledge to set up and configure

Code Comparison

v2ray-core (Go):

type User struct {
    Level uint32
    Email string
}

type Account struct {
    Id      string
    AlterId uint32
}

v2rayNG (Kotlin):

data class User(
    var level: Int = 0,
    var email: String = ""
)

data class Account(
    var id: String = "",
    var alterId: Int = 0
)

Summary

v2ray-core is the core implementation of the V2Ray protocol, offering robust functionality and performance. It's well-documented and supported by a large community. However, it lacks a built-in GUI and requires more technical expertise to use.

v2rayNG, on the other hand, is an Android client for V2Ray. It provides a user-friendly interface for configuring and using V2Ray on mobile devices. While it may not offer the same level of performance or flexibility as the core implementation, it's more accessible for average users.

The code comparison shows similarities in data structures between the two projects, with v2ray-core using Go and v2rayNG using Kotlin, reflecting their different target platforms and use cases.

113,831

A GUI client for Windows, Linux and macOS, support Xray and sing-box and others

Pros of v2rayN

  • More feature-rich and customizable for Windows users
  • Supports a wider range of protocols and configurations
  • Better suited for advanced users with more technical knowledge

Cons of v2rayN

  • Limited to Windows platform, less accessible for mobile or cross-platform users
  • May have a steeper learning curve for beginners
  • Potentially more complex interface compared to v2rayNG's mobile-friendly design

Code Comparison

v2rayN (C#):

public static int RunAsAdmin(string arguments)
{
    Process process = new Process();
    process.StartInfo.FileName = Utils.GetExePath();
    process.StartInfo.Arguments = arguments;
    process.StartInfo.UseShellExecute = true;
    process.StartInfo.Verb = "runas";
    process.Start();
    return process.Id;
}

v2rayNG (Kotlin):

fun startV2Ray() {
    if (!v2rayPoint.isRunning) {
        val result = v2rayPoint.runLoop()
        if (result) {
            MessageUtil.sendMsg2UI(this, AppConfig.MSG_STATE_START_SUCCESS, "")
        } else {
            MessageUtil.sendMsg2UI(this, AppConfig.MSG_STATE_START_FAILURE, "")
        }
    }
}

The code snippets demonstrate different approaches to starting processes or services, reflecting the distinct platforms and languages used in each project.

A shadowsocks client for Android

Pros of shadowsocks-android

  • Simpler and more lightweight protocol, potentially faster for basic usage
  • Longer development history and wider adoption
  • More straightforward setup process for users

Cons of shadowsocks-android

  • Less advanced features compared to v2rayNG
  • Limited protocol support (primarily Shadowsocks)
  • May be less effective against sophisticated network censorship

Code Comparison

shadowsocks-android:

override fun onStartCommand(intent: Intent?, flags: Int, startId: Int): Int {
    if (intent?.action == Action.CLOSE) stopRunner()
    return Service.START_NOT_STICKY
}

v2rayNG:

override fun onStartCommand(intent: Intent?, flags: Int, startId: Int): Int {
    when (intent?.action) {
        Action.SERVICE_START -> startV2Ray()
        Action.SERVICE_STOP -> stopV2Ray()
    }
    return super.onStartCommand(intent, flags, startId)
}

Both projects use Kotlin and have similar service lifecycle management. However, v2rayNG appears to have more granular control over service actions, reflecting its more feature-rich nature compared to the simpler shadowsocks-android implementation.

19,750

An unidentifiable mechanism that helps you bypass GFW.

Pros of trojan

  • Simpler and more lightweight protocol, potentially faster
  • Designed to be undetectable, mimicking HTTPS traffic
  • Cross-platform support with implementations in multiple languages

Cons of trojan

  • Less feature-rich compared to v2rayNG's multi-protocol support
  • Smaller community and ecosystem
  • Limited built-in obfuscation options

Code Comparison

v2rayNG (Kotlin):

override fun onBind(intent: Intent): IBinder? {
    return VpnService.prepare(this)
}

trojan (C++):

int main(int argc, char *argv[]) {
    Log::log_with_date_time("Welcome to trojan " + Version::get_version(), Log::FATAL);
    return run_service(argc, argv);
}

v2rayNG is an Android client for the V2Ray core, offering a user-friendly interface and support for multiple protocols. It's written in Kotlin and focuses on mobile usage.

trojan is a lightweight proxy tool designed to bypass network restrictions. It's implemented in C++ and aims for simplicity and undetectability.

Both projects serve similar purposes but differ in their approach and target platforms. v2rayNG offers more flexibility with multiple protocols, while trojan focuses on a single, efficient protocol designed to be undetectable.

Convert Figma logo designs to code with AI

Visual Copilot

Introducing Visual Copilot: A new AI model to turn Figma designs to high quality code using your components.

Try Visual Copilot

README

v2rayNG

A V2Ray client for Android, support Xray core and v2fly core

API Kotlin Version GitHub commit activity CodeFactor GitHub Releases Chat on Telegram


Download / 下载

Download the latest release here:

在这里下载最新版本:

https://github.com/2dust/v2rayNG/releases

[!TIP] v2rayNG is the mobile version. For the desktop version, please visit the v2rayN
v2rayNG 是手机版,电脑版请访问 v2rayN

https://github.com/2dust/v2rayN


Geoip and Geosite

  • geoip.dat and geosite.dat files are in Android/data/com.v2ray.ang/files/assets (path may differ on some Android device)
  • download feature will get enhanced version in this repo (note: it needs a working proxy)
  • latest official domain list and ip list can be imported manually
  • possible to use a third-party dat file in the same folder, like h2y

More in our wiki

Geoip 与 Geosite

  • geoip.dat 和 geosite.dat 文件位于 Android/data/com.v2ray.ang/files/assets(部分设备路径可能不同)
  • 下载功能将获取该 仓库 中的增强版本(注意:此功能需要一个可用的代理)
  • 最新官方 域名列表 和 IP 列表 可手动导入
  • 也可在同一文件夹中使用第三方 dat 文件,例如 h2y

更多内容请见我们的 wiki


Development guide / 开发指南

Note

  • Android project under the V2rayNG folder can be compiled directly in Android Studio, or using the Gradle wrapper. But the v2ray core inside the aar is (probably) outdated.
  • The aar can be compiled from the Golang project AndroidLibV2rayLite or AndroidLibXrayLite. For a quick start, read the guides for Go Mobile and Makefiles for Go Developers.
  • v2rayNG can run on Android Emulators. For WSA, VPN permission needs to be granted via appops set [package name] ACTIVATE_VPN allow.

提示

  • V2rayNG 文件夹下的 Android 项目可直接在 Android Studio 中编译,或使用 Gradle wrapper 编译。但 aar 内置的 v2ray core(可能)已过时。
  • aar 可由 Golang 项目 AndroidLibV2rayLite 或 AndroidLibXrayLite 编译而成。快速入门可参考 Go Mobile 指南和 Makefiles for Go Developers。
  • v2rayNG 可在 Android 模拟器上运行。对于 WSA,需要通过 appops set [package name] ACTIVATE_VPN allow 授予 VPN 权限。

GPG Verification / GPG 签名校验

Release files are signed with GPG to verify authenticity and integrity, helping prevent mirror, ISP, or CDN hijacking.

发布文件已使用 GPG 签名,可用于校验文件真实性与完整性,预防镜像站、运营商或 CDN 劫持。

Fingerprint / 公钥指纹

7694 5E9F 3E9A 168F 8070 F195 805D 661C
134D FAF6 8903 C199 463C 31E5 AE90 3AE0

Community / 社区

Telegram Group / Telegram 群组:

https://t.me/v2rayN

Telegram Channel / Telegram 频道:

https://t.me/github_2dust