Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I want to remove / hide Categories / Tags submenu under Posts in the Admin Menu. I know this works with themes submenus:

remove_submenu_page('themes.php', 'widgets.php');

but the same doesn't seem to work for posts:

remove_submenu_page('edit.php', 'edit-tags.php');

I'm using the admin_menu action: add_action('admin_menu', 'function_call')

Do I need to add something else?

share|improve this question

1 Answer 1

up vote 1 down vote accepted
add_action('admin_menu', 'my_remove_sub_menus');

function my_remove_sub_menus() {
    remove_submenu_page('edit.php', 'edit-tags.php?taxonomy=category');
    remove_submenu_page('edit.php', 'edit-tags.php?taxonomy=post_tag');
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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