After we published a guide on how to remove unwanted dashboard items from your admin panel, we’ll be showing you another productivity hack that can help you improve the user experience with WordPress. Using this hack, you can personalize the order of your WordPress dashboard menu items in such a way that the most used menu comes at the top.

Take a WordPress backup before you proceed just in case you make a mistake and need to revert the code.

{autotoc} 

Code tweak: WordPress Customize Admin Menu

For personalizing your dashboard menu, simply open your functions.php file, add the below code to the file and save it.

// CUSTOMIZE ADMIN MENU ORDER

  function custom_menu_order($menu_ord) {

  if (!$menu_ord) return true;

  return array(

   'index.php',

   'upload.php',

   'plugins.php',

   'edit-comments.php',

   'edit.php?post_type=page',

   'edit.php',

);

  }

  add_filter('custom_menu_order', 'custom_menu_order');

  add_filter('menu_order', 'custom_menu_order');

Before implementing the tweak, this is what the WordPress dashboard menu looked like.

wp dashboard menu before

This is how it looks after adding the above code snippet to the functions.php file.

wp dashboard menu after

WordPress Menu items explanation

Every user is different and will require a unique personalized order for their WordPress dashboard menu items. Look carefully at what each line inside the return array() means so that you can customize the order as per your preference (or your end users preference).

  • index.php- To display dashboard
  • upload.php- To display media
  • plugins.php- To display plugins
  • edit-comments.php- To display comments
  • edit.php?post_type=page- To display pages
  • edit.php- To display posts 

Did you find the above code useful? Share your thoughts with us below. Also if you're interested in other WordPress tips and tricks, check out our listing of more than 101 WordPress tricks here.

Download the list of 101 WordPress tricks every blogger should know

101 WordPress tricks

Click here to Download Now