Remove Unnecessary Widgets from WordPress Dashboard Easily
How to remove widgets from wordpress dashboard;
Disable unwanted widgets in wordpress;
Remove default wordpress dashboard widgets;
Clean up wordpress dashboard widgets;
Wordpress dashboard widget removal guide;
Delete unnecessary widgets in wordpress;
Hide widgets in wordpress admin panel;
Remove wordpress admin widgets;
Wordpress dashboard cleanup tips;
Manage wordpress widgets efficiently;
Explanation
Want to tidy up your WordPress dashboard by getting rid of those widgets you never use? Here's a simple way to do it!
What This Code Does:
- Removes the 'At a Glance' widget: This widget usually shows a summary of your site's content and activity.
- Removes the 'Activity' widget: This one displays recent comments and scheduled posts.
- Removes the 'Quick Draft' widget: A small box for jotting down quick post ideas.
- Removes the 'WordPress Events and News' widget: Keeps you updated with WordPress news and events.
- Removes the 'Welcome' panel: The introductory panel that appears for new users.
By adding this code to your theme's functions.php file, you can clean up your dashboard, making it less cluttered and more focused on what you actually use. This is especially handy if you want a streamlined admin experience without distractions.
Code
<?php
// Hook into the 'wp_dashboard_setup' action to remove unwanted dashboard widgets
add_action('wp_dashboard_setup', 'wp_dudecom_remove_dashboard_widgets');
/**
* Remove default WordPress dashboard widgets.
*/
function wp_dudecom_remove_dashboard_widgets() {
// Remove the 'At a Glance' widget
remove_meta_box('dashboard_right_now', 'dashboard', 'normal');
// Remove the 'Activity' widget
remove_meta_box('dashboard_activity', 'dashboard', 'normal');
// Remove the 'Quick Draft' widget
remove_meta_box('dashboard_quick_press', 'dashboard', 'side');
// Remove the 'WordPress Events and News' widget
remove_meta_box('dashboard_primary', 'dashboard', 'side');
// Remove the 'Welcome' panel
remove_action('welcome_panel', 'wp_welcome_panel');
}
?>
Instructions
File Location: functions.php
Prerequisites: None
Implementation Steps:
- Log in to your WordPress admin dashboard.
- Navigate to Appearance > Theme Editor. If you don't see this option, you might need to enable it or use an FTP client to access your theme files.
- In the Theme Editor, locate and select the
functions.php
file from the list on the right-hand side. - Copy the provided code snippet.
- Paste the code at the end of the
functions.php
file. - Click Update File to save your changes.
- Refresh your WordPress dashboard to see the changes. The unnecessary widgets should now be removed.
Need help with implementation or more advanced functionality? Visit wp-dude.com for expert WordPress services.