# Impersonate a user and returning to admin user

**URL:** https://meta.discourse.org/t/impersonate-a-user-and-returning-to-admin-user/119683
**Category:** Site Management
**Tags:** how-to, impersonate, users
**Created:** [6월 6, 2019, 7:09오후 UTC](https://meta.discourse.org/t/impersonate-a-user-and-returning-to-admin-user/119683 "2019-06-06T19:09:10Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![Discourse](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/discourse/32/148734_2.png) [@Discourse](https://meta.discourse.org/u/Discourse)
#### Post date: [6월 6, 2019, 7:09오후 UTC](https://meta.discourse.org/t/impersonate-a-user-and-returning-to-admin-user/119683/1 "2019-06-06T19:09:10Z")

</div>

> 🔖 This guide explains how to impersonate a user in Discourse and return to your admin account. This is useful when you need to troubleshoot issues faced by a specific user or verify their permissions.
> 
> 🙋 Required user level: Administrator

The admin can choose to impersonate another user when needed. This can be useful when a member is experiencing odd behavior or you need to check their permissions. Impersonating another user acts as if you are logged in as that user. This documentation will guide you through the process of impersonating a user as an admin and how to return to the admin account.

## Impersonating a User

1. Navigate to the **Admin** section of the sidebar and select **Users**.  

2. Find and select the profile of the user you want to impersonate.

3. Click on **Admin** in the top right corner.  

4. At the bottom, select the `Impersonate` button  
 ![image](https://global.discourse-cdn.com/meta/original/3X/1/9/197b528f131d63922de3b1987a5c40250800a0c7.png)

> ⚠ Impersonating a user is not transparent — it creates a logged visit for that user and resets any notification flags that are acted on. Consider communicating to the user that impersonation was performed.

## Terminating the impersonation session

### Method 1, good for infrequent use:

To stop impersonating and return to your admin account, simply log out from the impersonated user account and log back in as the admin.

> ℹ Logging in and impersonating in a private/incognito window prevents needing to log back in under your main browser session. Just close the incognito window and you’re good to go!

### Method 2, recommended if you frequently impersonate users

The `impersonate_without_logout` setting, when enabled, shows a persistent banner at the top of the interface while impersonating a user, with a button to immediately end the session and return to your admin account.

![image](https://global.discourse-cdn.com/meta/optimized/4X/d/7/5/d75ae379a48e0e944046f67f7b3b124c74626c4d_2_517x39.png)

This makes repeated impersonation workflows safer and more efficient, especially for support and QA.

Additionally, the hidden site setting `experimental_impersonation_time_limit_minutes` can be used to define a maximum duration for an impersonation session (default: 15 minutes). Once this time limit is reached, the session automatically terminates, adding an extra layer of safety.

#### Enabling `impersonate_without_logout`

The recommended way to enable this feature is via **Admin → Upcoming Changes** (`/admin/config/upcoming-changes`), where it can be toggled on for all staff or specific groups.

For **self-hosted** sites, it can also be enabled via the Rails console:

```ruby
SiteSetting.impersonate_without_logout = true
SiteSetting.experimental_impersonation_time_limit_minutes = 15

```

> Last edited by @dax 2026-05-15T18:17:47Z
> 
> > **Check document**
> >
> > Perform check on document:

---

<div class="post-metadata">

### Author: ![ToddZ](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/toddz/32/328350_2.png) [@ToddZ](https://meta.discourse.org/u/ToddZ)
#### Post date: [10월 1, 2024, 10:16오후 UTC](https://meta.discourse.org/t/impersonate-a-user-and-returning-to-admin-user/119683/5 "2024-10-01T22:16:45Z")

</div>

사용자를 위장하는 것은 투명하지 않다는 점을 참고할 가치가 있습니다. 해당 사용자에게 로그인된 방문 기록을 생성하고, 처리된 알림 플래그를 초기화하기 때문입니다. 실제 사용자에게 이 작업이 수행되고 있다는 점을 알리는 것이 가장 좋습니다.

---

<div class="post-metadata">

### Author: ![GaurangBlaze](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/gaurangblaze/32/279249_2.png) [@GaurangBlaze](https://meta.discourse.org/u/GaurangBlaze)
#### Post date: [11월 5, 2024, 7:12오전 UTC](https://meta.discourse.org/t/impersonate-a-user-and-returning-to-admin-user/119683/6 "2024-11-05T07:12:03Z")

</div>

저도 이 문제를 겪었습니다. 최소한 ‘Impersonate’ 버튼에 확인 다이얼로그를 추가할 수 있을까요? 현재는 경고 없이 즉시 impersonation이 시작되며, 특히 로그가 남는 방문 기록이 생성된다는 점에 대해 사용자에게 사전에 알려주지 않습니다.

인근의 다른 버튼들(예: ‘Delete user’)은 확인 다이얼로그가 있습니다. 사용자로서 저는 ‘Impersonate’ 버튼도 다른 버튼들과 마찬가지로 다이얼로그가 열리기를 기대합니다.

![image](https://global.discourse-cdn.com/meta/original/4X/6/3/a/63a18197930a6a00322862bfe77597058dcf8b53.png)

---

<div class="post-metadata">

### Author: ![ToddZ](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/toddz/32/328350_2.png) [@ToddZ](https://meta.discourse.org/u/ToddZ)
#### Post date: [11월 5, 2024, 7:24오전 UTC](https://meta.discourse.org/t/impersonate-a-user-and-returning-to-admin-user/119683/7 "2024-11-05T07:24:04Z")

</div>

확인 다이얼로그가 없다는 사실조차 눈치채지 못했지만, 그렇다고 해도 _해당 사용자로 전환_되고 흔적이 남는다는 점을 경고하기에 좋은 자리이긴 합니다. 단순히 백그라운드에서 아무 영향 없이 둘러보는 것이 아니라 말이에요.

---

<div class="post-metadata">

### Author: ![Moin](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/moin/32/554653_2.png) [@Moin](https://meta.discourse.org/u/Moin)
#### Post date: [2월 25, 2026, 10:38오후 UTC](https://meta.discourse.org/t/impersonate-a-user-and-returning-to-admin-user/119683/9 "2026-02-25T22:38:39Z")

</div>

> [@Discourse](#):
>
> **호스팅** Discourse 고객: 이러한 설정을 활성화하거나 구성하려면 지원팀에 문의하십시오.

지금 `/admin/config/upcoming-changes`에서 해당 설정을 활성화할 수 있다고 생각합니다.
