How To Remove Columns From Post or Page Screen In WordPress

WordPress comes with a few default columns like Title, Date, etc. on a Post or Page screen on the dashboard. When we install plugins, some of the plugins add custom columns on the Post or Page listing. For instance, the Yoast SEO plugin adds columns like SEO, Readability to the Post, and Page records.

How To Remove Columns From Post Page In WordPress

This number of columns may vary depending on the plugins used on the site. In such a case, you may want to remove default columns from these listing pages in WordPress.

Remove Columns From Post or Page Screen In WordPress

As mentioned on the codex, manage_posts_custom_column is a filter that adds or removes custom columns to the listing of Post.

Let’s say you want to remove columns like Tags, Author, Categories, and Comments from the Post listing. For removing these columns, place the below code in your theme’s functions.php file.

add_filter('manage_post_posts_columns', function ( $columns ) 
    unset($columns['tags'], $columns['author'], $columns['categories'], $columns['comments']);
    return $columns;
} );

The above code removes all 4 columns we have passed from your Post screen page.

‘Page’ is a built-in post type in WordPress. You can see it on the URL wp-admin/edit.php?post_type=page of your Page listing. Notice post_type=page on the URL. If you want to remove columns from the Page listing then your filter would be manage_page_posts_columns.

In the case of a custom post type, you need to use a filter manage_{$post_type}_posts_custom_column where {$post_type} is a placeholder that will replace by the actual post type name.

That’s it! This is the way to remove columns from the Post and Page screen in WordPress. You may also want to read our article on How To Display Post Views Count On Post Screen In WordPress.

If you liked this article, then please subscribe to our YouTube Channel for video tutorials.

5 thoughts on “How To Remove Columns From Post or Page Screen In WordPress

Leave a Reply

Your email address will not be published. Required fields are marked *