Is it possible to remove/add widgets from/to the Available Widgets pool (either by plugin or editing core files)?

There are 3 widget files located at:




I have tried to change both the code and the widget variables but nothing happened.


1 Answer 1


You can use the function unregister_widget to remove widgets.

E.g. you can remove the Calendar widget with:

function my_widgets_init() {
    unregister_widget( 'WP_Widget_Calendar' );
add_action('widgets_init', 'my_widgets_init');

To add widgets, use the Widgets API.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.