Is there a way to view only the published pages instead of all the pages on the wordpress dashboard? I almost never need to use the drafts, and I would like to be able to get to my published pages easier. Thanks in advance :) enter image description here


1 Answer 1


Try this solution. Works for me.

add_action( 'admin_menu', 'customize_pages_admin_menu_callback' );

function customize_pages_admin_menu_callback() {
    global $submenu;
    foreach ( $submenu['edit.php?post_type=page'] as $key => $value ) {
        if ( in_array( 'edit.php?post_type=page', $value ) ) {
            $submenu['edit.php?post_type=page'][ $key ][2] = 'edit.php?post_status=publish&post_type=page';

further, you can also hide All using CSS if needed.

    .post-type-page .subsubsub .all{ display:none}
  • Hi, thanks for the code :) I'm not familiar with wordpress, where am I supposed to paste this, please?
    – user227893
    Nov 29, 2022 at 13:35
  • You can place this code in your themes' functions.php file. Nov 29, 2022 at 13:41
  • 1
    YES, it worked! Thank you!
    – user227893
    Nov 29, 2022 at 15:27

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.