Login redirect functionality allows you to redirect a user to a specific page after they login. You can also specify a page to redirect the user after they logout. This functionality also limit the user from accessing “wp-admin” and also disable the admin bar/toolbar if required.
To add a new login redirect, click on the “Add New” button within the login redirect screen.
Add New Login Redirect
- Role – Select the role to set the login redirect configuration.
- Priority – When a user is assigned multiple roles, priority defines the order in which login redirect configuration is processed.
- Login Redirect URL – This is the URL where user will be redirected after login.
- Logout Redirect URL – This is the URL where user will be redirected after logout.
- Deny WP-ADMIN – If checked, user will be redirected back to the login redirect URL if they access any wp-admin page.
- Disable Toolbar – If checked, user won’t see the admin bar/toolbar on your WordPress site.
To edit a login redirect configuration, click on the role display name within the login redirect screen.
To delete a login redirect configuration, click on the “Delete” link available within the row actions. You can also delete multiple login redirect through bulk actions.
Custom Login Screens
Login redirect might not work with custom login screens. Login/Logout redirect works using WordPress standard filters. If the plugin/theme which implemented the custom login screen doesn’t follow the WordPress standard, then the login/logout filters won’t execute.
The easiest way to test this is to login through the wp-login.php page. If the login redirect worked using wp-login.php, but not using your custom login screen, then it’s an issue with the plugin/theme which implemented your login screen.