# How to Change WordPress Menu After Login: A Step-by-Step Guide

- Link: https://techaid24.com/change-wordpress-menu-after-login/
- Published: 2025-08-27T03:04:00+06:00
- Author: Anonymous Guest

For example, you want to show logged-in users a link to their profile and a link to sign in or register for users who are not logged in. In this article, I will show you, how to change menu after login or show different menus to logged-in users in two(2) ways in WordPress. Way 1: Using Nav Menu Roles plugins – This plugin will allow you to display your menu items based on the user role on your WordPress site. If you have a link in the menu that you only want to show to your vendors only, you can toggle that on the Menu page. Example : Way 2: Using manual code: In WordPress even if your theme has one menu location, you can still create multiple menus for the same location. Go to Appearance » Menus, create two menus logged-in and logged-out. After creating the menus, add this code to your theme’s functions.php file. function my_wp_nav_menu_args( $args = '' ) { if( is_user_logged_in() ) { $args['menu'] = 'logged-in'; } else { $args['menu'] = 'logged-out'; } return $args; } add_filter( 'wp_nav_menu_args', 'my_wp_nav_menu_args' ); 123456789101112 &nbsp;function my_wp_nav_menu_args( $args = '' ) {&nbsp;if( is_user_logged_in() ) { &nbsp;&nbsp;&nbsp;&nbsp;$args['menu'] = 'logged-in';} else { &nbsp;&nbsp;&nbsp;&nbsp;$args['menu'] = 'logged-out';} &nbsp;&nbsp;&nbsp;&nbsp;return $args;}add_filter( 'wp_nav_menu_args', 'my_wp_nav_menu_args' );&nbsp; That’s all you will see that you are logged-in visitors will see the logged-in menu and non-registered or logged-out users will see a different menu. This method allows you to create two different menus for your users so that you can freely update your menus for logged-in or logged-out users. Example: I hope this article helped you show different menus to logged-in users in your WordPress site. For questions and feedback please leave a comment below. How to change menu after login in WordPress
