A collection of scripts to customize the number of queries displayed in Pi-hole's dashboard for both v5 and v6.
These scripts allow you to modify how many queries are displayed in various sections of the Pi-hole dashboard, including:
- 📝 Top Permitted Domains
- 🚫 Top Blocked Domains
- 👥 Top Clients (total)
- ⛔ Top Clients (blocked only)
- 📌
pihole-change-queries-number_v5.bash
- Compatible with Pi-hole v5 - 📌
pihole-change-queries-number_v6.bash
- Compatible with Pi-hole v6
- 🔄 Reset to default values (10 queries)
- ⚡ Predefined optimal values for medium-sized servers
- 🎛️ Custom configuration (10-99 queries)
- 🎨 Color-coded terminal output (v6 script)
- 🔙 Restore functionality
- 🖥️ User-friendly interactive interface
- 🔑 Root access to your Pi-hole server
- 🚀 Running Pi-hole v5 or v6 installation
- 💻 Basic command line knowledge
-
Clone this repository:
git clone https://github.com/mapi68/pihole-script.git
-
Navigate to the script directory:
cd pihole-script
-
Make the script executable:
chmod +x pihole-change-queries-number_v6.bash # For Pi-hole v6 # OR chmod +x pihole-change-queries-number_v5.bash # For Pi-hole v5
sudo ./pihole-change-queries-number_v6.bash
sudo ./pihole-change-queries-number_v5.bash
Pi-hole v5 Optimal Mode Configuration
- ✅ Sets optimized values for a medium-sized Pi-hole server
- ✅ Top Domains: 15 entries
- ✅ Top Clients: 30 entries
Pi-hole v5 Manual Configuration
- 🔧 Customize the number of entries (10-99) for:
- Top Permitted Domains
- Top Blocked Domains
- Top Clients (total)
- Top Clients (blocked only)
Pi-hole v6 Optimal Mode Configuration
- ✅ Sets optimized values for a medium-sized Pi-hole server
- ✅ Enhanced color-coded interface
- ✅ Top Domains: 15 entries
- ✅ Top Clients: 30 entries
Pi-hole v6 Manual Configuration
- 🎨 Modern interface with color-coded messages
- 🔧 Customize the number of entries (10-99) for:
- Top Permitted Domains
- Top Blocked Domains
- Top Clients (total)
- Top Clients (blocked only)
Pi-hole Dashboard View (Same layout for both v5 and v6)
After running the script, you'll need to:
- 🔄 Refresh your Pi-hole web interface
- ✨ The new query numbers will be displayed in the dashboard
- 🔄 If you encounter any issues, the script will automatically download the original file from Pi-hole repository (v6)
- 🎨 Error messages are color-coded for easy identification
- ✅ Invalid inputs are properly handled with appropriate error messages
The script automatically resets to default values (10) before applying new ones. If you need to revert:
- 🔄 Run the script again
- ⏹️ Choose to exit after the reset
This project is licensed under the MIT License - see the LICENSE file for details.
If you encounter any issues or have questions, please open an issue on the GitHub repository.
Contributions are welcome! Please feel free to submit a Pull Request.