# Serve Discourse from a subfolder, Login redirects to root path

**URL:** https://meta.discourse.org/t/serve-discourse-from-a-subfolder-login-redirects-to-root-path/386619
**Category:** Bug
**Tags:** subfolder
**Created:** [October 24, 2025, 7:59am UTC](https://meta.discourse.org/t/serve-discourse-from-a-subfolder-login-redirects-to-root-path/386619 "2025-10-24T07:59:33Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![truman](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/truman/32/491648_2.png) [@truman](https://meta.discourse.org/u/truman)
#### Post date: [October 24, 2025, 7:59am UTC](https://meta.discourse.org/t/serve-discourse-from-a-subfolder-login-redirects-to-root-path/386619/1 "2025-10-24T07:59:33Z")

</div>

version:v3.5.1  
my website: [https://www.example.com/forum](https://www.example.com/forum)  
local login(homepage) will redirect to [https://www.example.com](https://www.example.com)

Logging in from a non-homepage does not have this issue.

log

```plaintext
Processing by StaticController#enter as HTML Parameters: {"username"=>" ****", "password"=>"[FILTERED]", "redirect"=>"https://www.example.com/forum/login"} Redirected to https://www.example.com/

```

---

<div class="post-metadata">

### Author: ![pmusaraj](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/pmusaraj/32/119489_2.png) [@pmusaraj](https://meta.discourse.org/u/pmusaraj)
#### Post date: [October 24, 2025, 1:44pm UTC](https://meta.discourse.org/t/serve-discourse-from-a-subfolder-login-redirects-to-root-path/386619/2 "2025-10-24T13:44:31Z")

</div>

Thanks for the report, we will look into it soonish.

---

<div class="post-metadata">

### Author: ![Thiago\_Mobilon](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/thiago_mobilon/32/177756_2.png) [@Thiago\_Mobilon](https://meta.discourse.org/u/Thiago_Mobilon)
#### Post date: [November 2, 2025, 4:02am UTC](https://meta.discourse.org/t/serve-discourse-from-a-subfolder-login-redirects-to-root-path/386619/5 "2025-11-02T04:02:33Z")

</div>

I have the same issue. Version: 3.6.0.beta3

---

<div class="post-metadata">

### Author: ![Magnetidog](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/magnetidog/32/116910_2.png) [@Magnetidog](https://meta.discourse.org/u/Magnetidog)
#### Post date: [December 10, 2025, 7:24pm UTC](https://meta.discourse.org/t/serve-discourse-from-a-subfolder-login-redirects-to-root-path/386619/6 "2025-12-10T19:24:34Z")

</div>

We are experiencing the same issue after installing 2025.12.0-latest.

---

<div class="post-metadata">

### Author: ![zogstrip](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/zogstrip/32/512781_2.png) [@zogstrip](https://meta.discourse.org/u/zogstrip)
#### Post date: [December 10, 2025, 10:47pm UTC](https://meta.discourse.org/t/serve-discourse-from-a-subfolder-login-redirects-to-root-path/386619/7 "2025-12-10T22:47:37Z")

</div>

@here sorry about that, I think I managed to reproduce and fix the issue

[https://github.com/discourse/discourse/pull/36609](https://github.com/discourse/discourse/pull/36609)

---

<div class="post-metadata">

### Author: ![zogstrip](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/zogstrip/32/512781_2.png) [@zogstrip](https://meta.discourse.org/u/zogstrip)
#### Post date: [December 12, 2025, 7:00am UTC](https://meta.discourse.org/t/serve-discourse-from-a-subfolder-login-redirects-to-root-path/386619/8 "2025-12-12T07:00:36Z")

</div>

This topic was automatically closed after 16 hours. New replies are no longer allowed.
