A cross-platform GUI tool for automatically switching Clash proxies at scheduled intervals.
- ⏰ Scheduled Switching - Automatically switch proxies at customizable intervals
- ✅ Availability Check - Verify proxy connectivity before switching
- 🔄 Real-time Sync - Sync with Clash Verge in real-time
- 🌍 Multi-language - Supports English and Simplified Chinese
- 💾 Persistent Config - Settings are saved automatically
- 🖥️ Cross-platform - Works on Windows and macOS
Download the latest release for your platform from Releases:
- Windows:
ClashProxyTimer.exe - macOS (Apple Silicon):
ClashProxyTimer-macOS-arm64.zip
# Clone the repository
git clone https://github.com/fengyiyang/clash-proxy-timer.git
cd clash-proxy-timer
# Install dependencies (using uv - recommended)
uv sync
# Run
uv run python main.pyOr using pip:
pip install -r requirements.txt
python main.py- Python 3.8+
- Clash Verge (or any Clash-based proxy tool) running
- Clash External Controller API enabled (default port: 9097)
- Start the app - It will auto-detect your Clash settings
- Select proxy group - Choose the group you want to auto-switch
- Set interval - Configure how often to switch (in seconds)
- Start - Click "Start Auto Switch" button
The app will:
- Switch to a random available proxy at each interval
- Check proxy availability before switching (optional)
- Show countdown timer until next switch
Settings are stored in:
- Windows:
%APPDATA%/clash-proxy-timer/config.json - macOS/Linux:
~/.clash-proxy-timer/config.json
# Install build dependencies
uv pip install pyinstaller
# Build
uv run pyinstaller build.specMIT License
一个跨平台的 Clash 代理定时自动切换工具,带有图形界面。
- ⏰ 定时切换 - 按自定义间隔自动切换代理
- ✅ 可用性检测 - 切换前验证代理连通性
- 🔄 实时同步 - 与 Clash Verge 实时同步状态
- 🌍 多语言 - 支持简体中文和英文
- 💾 配置持久化 - 设置自动保存
- 🖥️ 跨平台 - 支持 Windows 和 macOS
从 Releases 下载适合你系统的版本:
- Windows:
ClashProxyTimer.exe - macOS (Apple Silicon):
ClashProxyTimer-macOS-arm64.zip
# 克隆仓库
git clone https://github.com/fengyiyang/clash-proxy-timer.git
cd clash-proxy-timer
# 安装依赖(使用 uv - 推荐)
uv sync
# 运行
uv run python main.py或使用 pip:
pip install -r requirements.txt
python main.py- Python 3.8+
- Clash Verge(或其他基于 Clash 的代理工具)正在运行
- Clash 外部控制 API 已启用(默认端口:9097)
- 启动应用 - 程序会自动检测 Clash 设置
- 选择代理组 - 选择要自动切换的代理组
- 设置间隔 - 配置切换间隔(秒)
- 开始 - 点击"开始自动切换"按钮
程序将会:
- 每隔设定时间随机切换到一个可用代理
- 切换前检测代理可用性(可选)
- 显示距下次切换的倒计时
在 Clash Verge 中:
- 打开设置
- 找到 Clash 设置
- 查看 外部控制 端口(通常是 9097)
- Windows:
%APPDATA%/clash-proxy-timer/config.json - macOS/Linux:
~/.clash-proxy-timer/config.json
支持自动切换 爱加速 客户端的节点。原理是把一段 JS 桥脚本注入到爱加速的 res.fvr(Sciter UI 资源包),由它在程序内部轮询命令文件,本工具通过文件 IPC 调用爱加速的 vpnConnect / pingMultiServer 等内部接口。
仅支持 Windows(因为 AJiaSu.exe 只在 Windows 上运行)。
使用步骤:
- 顶部"模式"切到 爱加速
- 点 ⚙ 展开设置面板
- 选择 AJiaSu 安装目录(也可点"自动"试着自动找),目录里要有
AJiaSu.exe和res.fvr - 关闭 AJiaSu.exe,然后点"安装桥接" — 工具会备份原始
res.fvr到res.fvr.bak,再注入ajiasu_bridge.js - 启动 AJiaSu.exe,等到主窗口出来,顶部状态会变成"● 爱加速桥已在线"
- 选分组(全部 / 收藏 / 最近,或按地区)、设置间隔,点开始
如需还原,点"卸载桥接"即可(优先用备份恢复)。
桥接通信文件位于 C:\Users\Public\AJiaSu\ 下,由 AJiaSu 进程内 JS 创建。
详细的架构、协议、xcall 依赖、故障排查 SOP 见 docs/AJIASU_MODE.md。
# 安装构建依赖
uv pip install pyinstaller
# 构建
uv run pyinstaller build.specMIT License
clash-proxy-timer/
├── main.py # Entry point / 入口文件
├── gui.py # GUI module / 界面模块
├── clash_api.py # Clash API client / Clash API 客户端
├── clash_detector.py # Auto-detect Clash settings / 自动检测 Clash 设置
├── proxy_checker.py # Proxy availability checker / 代理检测器
├── scheduler.py # Task scheduler / 定时任务调度
├── config.py # Configuration manager / 配置管理
├── i18n.py # Internationalization / 国际化
├── build.spec # PyInstaller config / 打包配置
├── pyproject.toml # Project metadata / 项目元数据
├── requirements.txt # Dependencies / 依赖列表
└── README.md # Documentation / 文档
Contributions are welcome! Please feel free to submit a Pull Request.
欢迎贡献!请随时提交 Pull Request。
- Clash - A rule-based tunnel
- Clash Verge - Clash GUI client
- CustomTkinter - Modern UI for Tkinter

