Skip to main content

User Switching

The User Switching plugin (plugins/user-switching/) allows administrators to instantly switch the active WordPress session from their admin account to any other user account — and back again — without knowing the user's password.


Plugin Details

PropertyValue
PluginUser Switching
Locationplugins/user-switching/
AuthorJohn Blackbourn

Use Cases

  • Support — Allow admins and support staff to experience exactly what a dealer sees in their account, without sharing credentials.
  • Debugging — Reproduce pricing issues, order problems, or access restrictions as a specific dealer.
  • QA — Test sub-account behaviour by switching between parent and sub-user accounts.

How to Use

Switch to a User

  1. Go to WP Admin → Users.
  2. Hover over the target dealer's username.
  3. Click Switch To in the action row.

You are now browsing as that dealer. The admin bar shows a "Switch back to [Your Name]" link.

Switch Back

Click Switch back to [Your Name] in the admin bar, or go to /wp-admin/ and click the switch-back link.


Security Notes

  • Only users with the switch_users capability can use this feature (administrators by default).
  • All switch events are logged in the WordPress error log for audit purposes.
  • Switching into a user does not grant the less-privileged user admin capabilities — your session takes on only the exact capabilities of the target user.
  • The switch-back token is stored in a browser cookie and expires when the browser closes.

Capability Management

Use User Role Editor Pro (plugins/user-role-editor-pro/) to grant the switch_users capability to non-administrator roles (e.g., support staff) if needed.