Skip to content

Repository files navigation

v2sing

v2sing is a tool designed to seamlessly convert subscription links from the v2 or clash subscription formats to the sing-box format, ensuring compatibility and simplifying migration.

Supported Protocols

ProtocolConversion (v2/clash → sing-box)
VMess
VLESS
Shadowsocks
Trojan
Hysteria2

Installation

You can self-host this project or deploy it to Cloudflare Workers. To deploy the project to Cloudflare Workers, download the latest release of v2sing from the Releases page and deploy it directly to the Cloudflare Workers instance you created.

Usage

Use the v2sing tool by providing specific parameters. Below are the currently available parameters:

  • sub (required) - The subscription URL to convert.
    • Example: ?sub=https://example.com/sub
  • config (optional) - The configuration template URL for advanced output customization. See Creating a Configuration Template section for more details.
    • Example: ?sub=https://example.com/sub&config=https://example.com/config_template.json

Available Templates

Versioned templates are in the templates directory, with filenames indicating the target sing-box version.

sing-box versionStatusTemplate
1.13DefaultView template

Creating a Configuration Template

You can create a configuration template just like a regular sing-box configuration file, but with placeholders to dynamically insert information from the subscription.

To create your own template, start with one of the versioned templates, which you can customize to suit your requirements.

Placeholders are written in the format {{ placeholder_name }} and are replaced with actual values at runtime.

Here are the currently available placeholders:

  • {{ outbounds_tags }} - This placeholder is replaced with an array of outbound tags.
  • {{ outbounds }} - This placeholder is replaced with a list of outbound configurations.

Development

Deno 2.0 or later is required.

deno task serve # Serve source in watch mode
deno task check # Run format, lint, type, and test checks
deno task build # Write build artifacts to dist/
deno task preview # Build and preview the production bundle
deno task clean # Remove generated build artifacts

Changelog

See the CHANGELOG.md file for more information.

License

This project is licensed under the AGPLv3 License. See the LICENSE file for more information.

Credits

Copyright © 2024-2026 Printfer

About

v2sing is a tool designed to seamlessly convert subscription links from the v2 or clash subscription formats to the sing-box format, ensuring compatibility and simplifying migration.

Topics

Resources

Stars

6 stars

Watchers

2 watching

Forks

Releases

Used by

Contributors

Languages