Title: Doesn&#8217;t work a second time
Last modified: November 18, 2025

---

# Doesn’t work a second time

 *  [coopersita](https://wordpress.org/support/users/coopersita/)
 * (@coopersita)
 * [6 months, 2 weeks ago](https://wordpress.org/support/topic/doesnt-work-a-second-time/)
 * After impersonating a user, I don’t seem to be able to do it again.
 * When I impersonate someone, and click the button to stop impersonating, if I 
   then try to impersonate the same user again, it doesn’t do it. It just takes 
   me to the homepage, but as myself (no bar at the bottom with the button to stop
   impersonating someone).
 * After some time, I can do it again, but I couldn’t say how long I have to wait.
 * Any idea why?

Viewing 3 replies - 1 through 3 (of 3 total)

 *  Plugin Author [Yiannis Christodoulou](https://wordpress.org/support/users/yiannistaos/)
 * (@yiannistaos)
 * [6 months, 2 weeks ago](https://wordpress.org/support/topic/doesnt-work-a-second-time/#post-18724215)
 * Hi [@coopersita](https://wordpress.org/support/users/coopersita/),
 * What is your WordPress version?
    Do you have any other plugins that handle user
   authentication?
 *  Thread Starter [coopersita](https://wordpress.org/support/users/coopersita/)
 * (@coopersita)
 * [6 months, 2 weeks ago](https://wordpress.org/support/topic/doesnt-work-a-second-time/#post-18724319)
 * Hi,
 * The only other plugin that deals with authentication is Profile Builder.
 * We also have a staging site, with the same plugins and themes installed, and 
   it works fine there.
 * Thanks for replying
 *  Plugin Author [Yiannis Christodoulou](https://wordpress.org/support/users/yiannistaos/)
 * (@yiannistaos)
 * [6 months, 2 weeks ago](https://wordpress.org/support/topic/doesnt-work-a-second-time/#post-18724533)
 * Hi [@coopersita](https://wordpress.org/support/users/coopersita/),
 * Thanks for the additional details. Since your staging environment works fine 
   with the same plugins and themes, this points to a server or configuration difference
   between the two environments.
 * **Here are a few things to investigate:**
 * 1. **Session/Cookie Issues**: The time delay before you can impersonate again
   suggests a session or cookie caching issue. Check if your production server has
   any aggressive session caching or cookie handling that differs from staging.
 * 2. **Server Configuration**:
    – Are both environments running the same server
   software (Apache/Nginx) and PHP version? – Check if there are differences in 
   PHP session settings (session.gc_maxlifetime, session.cookie_lifetime) – Compare
   any security plugins or server-level security rules between the two
 * 3. **Caching Layers**:
    – Do you have server-side caching (Redis, Memcached) 
   on production that’s not on staging? – Any full-page caching that might be interfering?–
   CloudFlare or CDN caching differences?
 * 4. **Profile Builder Compatibility**: Since Profile Builder handles authentication,
   there might be a conflict in how it manages user sessions. Try temporarily deactivating
   Profile Builder on production to see if the issue persists.
 * **Quick tests to try:**
    – Clear all caches (server, plugin, browser) – Try the
   impersonation in an incognito/private browser window – Check your browser’s developer
   console for any JavaScript errors when the redirect happens – Review your error
   logs during the failed impersonation attempt
 * Could you also confirm your WordPress and PHP versions on both environments? 
   This will help narrow down if it’s a version-specific issue.
 * Let me know what you find!
 * Regards,
    Yiannis
    -  This reply was modified 6 months, 2 weeks ago by [Yiannis Christodoulou](https://wordpress.org/support/users/yiannistaos/).

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Doesn’t work a second time’ is closed to new replies.

 * ![](https://ps.w.org/login-as-user/assets/icon-256x256.png?rev=3547432)
 * [Login as User](https://wordpress.org/plugins/login-as-user/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/login-as-user/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/login-as-user/)
 * [Active Topics](https://wordpress.org/support/plugin/login-as-user/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/login-as-user/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/login-as-user/reviews/)

 * 3 replies
 * 2 participants
 * Last reply from: [Yiannis Christodoulou](https://wordpress.org/support/users/yiannistaos/)
 * Last activity: [6 months, 2 weeks ago](https://wordpress.org/support/topic/doesnt-work-a-second-time/#post-18724533)
 * Status: not resolved