A 100% compatible drop-in fork of Marzban and Marzdar featuring a completed UI plus native reseller quotas, user limits, overselling controls, and inbound restrictions.
English / فارسی / 简体中文 / Русский
Marzyar is the reseller-ready evolution of Marzdar and Marzban.
While Marzdar focuses on completing the missing user interface elements of upstream Marzban, Marzyar integrates native reseller management capabilities directly into the core engine while guaranteeing zero database schema disruption and 100% bidirectional migration safety:
- User Account Limits: Cap the number of user accounts a reseller admin can create.
- Bandwidth Quotas & Oversell Controls:
- Unified Consumed Limit: In all modes, total consumed bandwidth (
∑ active_usage + historical_resets_and_deletions) can never exceed the admin'straffic_limit. - Strict Mode (No Oversell): Additionally limits the sum of allocated user data limits (
∑ user.data_limit ≤ traffic_limit). Resellers cannot over-allocate or create accounts with unlimited bandwidth. - Oversell Mode: Removes the allocation limit. Resellers can allocate user plans freely until actual traffic consumed reaches the quota limit.
- Non-bypassable Accounting: Reseller admins cannot reset or delete users to escape their quota; past usage is securely accumulated into the reseller's historical consumption counter.
- Unified Consumed Limit: In all modes, total consumed bandwidth (
- The "Locked" State Machine:
- When an admin exhausts their quota, their active users are non-destructively marked as
lockedand detached from Xray inbounds (traffic blocked immediately). - Core
userstable records remain untouched. - When Sudo resets or increases the reseller's quota, all locked users are automatically unlocked and restored to Xray in real-time.
- When an admin exhausts their quota, their active users are non-destructively marked as
- Allowed Inbounds: Restrict each reseller to specific protocols and inbounds (e.g., VMess TCP only).
- Dashboard Header Reseller Widget: Compact live indicators displaying remaining slots and quota for logged-in reseller admins.
| Feature | Marzban (Upstream) | Marzdar | Marzyar |
|---|---|---|---|
| Compatibility | Upstream | 100% Drop-in | 100% Drop-in (Zero DB alterations) |
| Complete Web UI | ❌ (CLI/API only for many features) | ✅ Complete | ✅ Complete |
| Reseller User Limits | ❌ None | ❌ None | ✅ Native & UI-managed |
| Bandwidth Quota & Oversell | ❌ None | ❌ None | ✅ Native & Non-bypassable |
| Auto-Lock on Over-Quota | ❌ None | ❌ None | ✅ Real-time Xray detach/restore |
| Allowed Inbounds Filtering | ❌ None | ❌ None | ✅ Admin-level restriction |
| Bidirectional Rollback | Baseline | ✅ Safe | ✅ 100% Safe (No custom Alembic revisions) |
Simply update the image in docker-compose.yml:
services:
marzban:
image: mehrwizard/marzyar:latestThen restart:
marzban updateIf you find Marzyar useful, you can support its ongoing development:
Marzyar is licensed under the GNU Affero General Public License v3.0 (AGPL-3.0).