# WP Discourse login page path

**URL:** https://meta.discourse.org/t/wp-discourse-login-page-path/103780
**Category:** WordPress
**Created:** [December 8, 2018, 7:59am UTC](https://meta.discourse.org/t/wp-discourse-login-page-path/103780 "2018-12-08T07:59:32Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![RickU](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/ricku/32/126290_2.png) [@RickU](https://meta.discourse.org/u/RickU)
#### Post date: [December 8, 2018, 7:59am UTC](https://meta.discourse.org/t/wp-discourse-login-page-path/103780/1 "2018-12-08T07:59:32Z")

</div>

@simon I have a similar situation to this:

> [@WP-Discourse Force SSO?](https://meta.discourse.org/t/wp-discourse-force-sso/91932/5):
>
> I try to go /wp-admin, but wait, my login has expired so I need to login again, wordpress then redirects me to the wp-login page or even loads the login

I want Wordpress to be the provider (the authentication come from Wordpress to Discord), and I am able to accomplish this, but the problem is that for the admin page I still want to be able to go to [www.mysite.com/wp-admin](http://www.mysite.com/wp-admin) and have the admin sign in there to do Wordpress maintenance and tha is not happening because now anytime anyone types [mysite.com/wp-admin](http://mysite.com/wp-admin) it takes them to a login page that is being managed by another plugin that I use.

So what I want is the following:

If anyone types [discourse.mysite.com](http://discourse.mysite.com) or get to my discourse through a link they get presented with a customized login page.

At the same time if anyone types [mysite.com/wp-admin](http://mysite.com/wp-admin) it takes them to the normal Wordpress Admin login. How do I accomplish this?

Thanks so much.

---

<div class="post-metadata">

### Author: ![simon](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/simon/32/339122_2.png) [@simon](https://meta.discourse.org/u/simon)
#### Post date: [December 8, 2018, 5:42pm UTC](https://meta.discourse.org/t/wp-discourse-login-page-path/103780/2 "2018-12-08T17:42:55Z")

</div>

> [@WP-Discourse Force SSO?](https://meta.discourse.org/t/wp-discourse-force-sso/91932/10):
>
> So what I want is the following:
> 
> If anyone types [discourse.mysite.com](http://discourse.mysite.com) or get to my discourse through a link they get presented with a customized login page.
> 
> At the same time if anyone types [mysite.com/wp-admin](http://mysite.com/wp-admin) it takes them to the normal Wordpress Admin login.

On the [WP Discourse](https://github.com/discourse/wp-discourse) SSO Provider settings page there is a ‘Path to your Login Page’ setting. It sets the login path that is used for SSO. Try entering the path to the login page that you want users to be redirected to when they login through `discourse.mysite.com`. The setting takes a path, not a full URL. It should look something like this: `/my-account`.

This should allow users who visit `/mysite.com/wp-admin` to be redirected to `/wp-login.php`, and users who initiate login visiting your forum to be redirected to your custom login page.

---

<div class="post-metadata">

### Author: ![RickU](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/ricku/32/126290_2.png) [@RickU](https://meta.discourse.org/u/RickU)
#### Post date: [December 8, 2018, 7:59pm UTC](https://meta.discourse.org/t/wp-discourse-login-page-path/103780/3 "2018-12-08T19:59:02Z")

</div>

Thanks so much, @simon.

I did this and for my /login path (which is the customized login I was referring to) and it works great. The problem here is that it is redirecting even those that type /wp-admin to /login, and I was just hoping to have 2 different paths.

1. If user types on the browser either /login or [discourse.mysite.com](http://discourse.mysite.com) then redirect to ➡ /login
2. if user types /wp-admin it simply stays there and log in through there. But what is happening instead is:  
2a. /wp-admins redirects to ➡ /login and once completed re-direct back to ➡ /wp-admin.

The general idea is to have all regular users go through **/login** and all admins through **/wp-admin**.

Thanks for your help.

---

<div class="post-metadata">

### Author: ![simon](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/simon/32/339122_2.png) [@simon](https://meta.discourse.org/u/simon)
#### Post date: [December 8, 2018, 8:12pm UTC](https://meta.discourse.org/t/wp-discourse-login-page-path/103780/4 "2018-12-08T20:12:06Z")

</div>

> [@RickU](#):
>
> if user types /wp-admin it simply stays there and log in through there. But what is happening instead is:  
> 2a. /wp-admins redirects to ➡ /login and once completed re-direct back to ➡ /wp-admin.

Check to see if the plugin you are using to create the login page at `/login` is overriding the WordPress login URL. By default, the login URL is at `/wp-login.php`.

---

<div class="post-metadata">

### Author: ![ValGun](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/valgun/32/309935_2.png) [@ValGun](https://meta.discourse.org/u/ValGun)
#### Post date: [June 30, 2023, 4:55am UTC](https://meta.discourse.org/t/wp-discourse-login-page-path/103780/5 "2023-06-30T04:55:48Z")

</div>

Is there any #how-to manual here on how to create WP page as front/login page?

---

<div class="post-metadata">

### Author: ![angus](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/angus/32/341715_2.png) [@angus](https://meta.discourse.org/u/angus)
#### Post date: [June 30, 2023, 10:02am UTC](https://meta.discourse.org/t/wp-discourse-login-page-path/103780/6 "2023-06-30T10:02:00Z")

</div>

Hey there @ValGun, could you explain a bit more what you mean? Are you trying to do the same thing as described in this topic? If so, have you tried the suggested solution?

> [@simon](#):
>
> On the WP [Discourse SSO](https://meta.discourse.org/t/13045) Provider settings page there is a ‘Path to your Login Page’ setting. It sets the login path that is used for SSO. Try entering the path to the login page that you want users to be redirected to when they login through `discourse.mysite.com`. The setting takes a path, not a full URL. It should look something like this: `/my-account`.
> 
> This should allow users who visit `/mysite.com/wp-admin` to be redirected to `/wp-login.php`, and users who initiate login visiting your forum to be redirected to your custom login page.
