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.bashsudo ./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.