Fix XUI.one Backup

🛠️ How to Fix XUI.one Backup Bug – Full Tutorial & Script
The XUI.one IPTV panel is widely used but suffers from long-standing issues—one of the most notorious being its non-functional backup system. For years, users have relied on manual backup scripts or cron-based workarounds, but today we bring you a clean, native fix that restores full backup and restore functionality without editing any core XUI files.
📌 What Is the XUI.one Backup Issue?
Despite having built-in backup and restore features, XUI.one’s automatic backup system doesn’t work out of the box.
❗ Why?
The core PHP code actually works as intended—so this is not a bug in the backups themselves. The real issue comes from the installer script, which doesn’t properly set database access permissions for local and IPv6 addresses.
This means backup tasks silently fail due to lack of access.
🔐 Why Is Backup So Important for IPTV Panels?
- 💾 Keeps your entire IPTV system safe
- 💡 Essential for migrating to a new server
- 🔄 Helps restore from hardware failure or mistakes
- ✅ Gives you peace of mind with automated recovery
Having a working native backup is critical. It can be the difference between quick recovery or losing everything.
🧪 Fixing the XUI.one Backup Bug: Our Journey
We started this investigation by decoding and reverse-engineering two key files:
/home/xui/www/admin/backups.php
/home/xui/crons/backups.php
After several hours of decoding obfuscated functions, we discovered that the admin-side file was irrelevant to the issue. All the logic responsible for automatic backup execution lives in crons/backups.php
.
We cleaned, rebuilt and tested the decoded file—and it turns out, nothing in the code was broken.

The fix? A simple permissions script.
⚙️ How to Fix XUI.one Backups (Step-by-Step)
✅ Step 1: Download the Fix Script
👤 You are currently browsing as a guest or free member.
✨ Upgrade to Premium to unlock full access instantly!
This script grants correct MySQL access to the XUI user via localhost
, 127.0.0.1
and ::1
(IPv6).
✅ It does not edit any XUI.one source files.
✅ It works instantly.
✅ It’s open-source—you can verify and modify it as you wish.
📥 Get the Cleaned Source Code (Optional)
Want to study or extend the script?
Download the fully decoded, working version of backups.php
:
👉 Download backups.php – IPTVTools
👤 You are currently browsing as a guest or free member.
✨ Upgrade to Premium to unlock full access instantly!
You can now develop:
- 📤 Upload backups to cloud storage
- 📲 Get Telegram notifications
- ⚙️ Add custom retention logic
🧩 Step 2: Manual Execution (Optional Test)
If you want to test it directly:
sudo -u xui /home/xui/bin/php/bin/php /home/xui/crons/backups.php
🧠 Conclusion: It Was Never Broken
The XUI.one backup system was never truly broken—just misconfigured.
Thanks to a bit of reverse engineering and patience, we now have a clean, working fix that doesn’t require hacking or modifying the core panel.
📌 Always backup your IPTV panel. It’s the easiest way to protect your service, clients, and your business.
💡 Brought to You by IPTVTools.io
We’re dedicated to improving the IPTV experience by providing tutorials, tools, and documentation you can trust.