# SSO Settings Help

**URL:** https://meta.discourse.org/t/sso-settings-help/73505
**Category:** WordPress
**Created:** [2017年十一月6日 11:45 UTC](https://meta.discourse.org/t/sso-settings-help/73505 "2017-11-06T11:45:55Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![charliel](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/charliel/32/120555_2.png) [@charliel](https://meta.discourse.org/u/charliel)
#### Post date: [2017年十一月6日 11:45 UTC](https://meta.discourse.org/t/sso-settings-help/73505/1 "2017-11-06T11:45:55Z")

</div>

We run a WordPress site and want to use Discourse as our forum, to replace bbPress.

Our current issue is that if a new user (not registered on WP) is on Discourse, clicks login then registers through WP, he ends up on our homepage, not the forum page. Now I’m wondering if this is because right now our Discourse forum is on [oursitename.ourhostingsite.net](http://oursitename.ourhostingsite.net) so the domains are different.

Then I’m looking in the settings and wondering if

enable sso provider

Implement [Discourse SSO](https://meta.discourse.org/t/13045?silent=true) provider protocol at the /session/sso\_provider endpoint, requires sso\_secret to be set

Should be ticked? Currently we have ticked enable sso and filled in the sso url and secret.

So basically, what’s the difference between enable sso and enable sso provider? Should both be ticked? Why might new users not be re-directed to the forum after signup?

Thanks.

---

<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: [2017年十一月6日 16:33 UTC](https://meta.discourse.org/t/sso-settings-help/73505/2 "2017-11-06T16:33:32Z")

</div>

> [@charliel](#):
>
> So basically, what’s the difference between enable sso and enable sso provider? Should both be ticked?

I thing you have it setup correctly. The enable\_sso setting on Discourse is the one you need to have checked. It’s for using WordPress as the SSO provider for Discourse. The Discourse enable\_sso\_provider setting is for using Discourse as the SSO provider for another site.

Your settings on Discourse should look like this - with a better sso\_secret:

 ![example](https://global.discourse-cdn.com/meta/original/4X/2/7/3/27371222f769073f860a9e4c19f5b0727ffc9032.png)

> [@charliel](#):
>
> Why might new users not be re-directed to the forum after signup?

Usually when this happens it’s because there is another plugin on your site that is performing a redirect after login - redirecting users to your homepage. Do you have any plugins that could be doing this?

---

<div class="post-metadata">

### Author: ![charliel](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/charliel/32/120555_2.png) [@charliel](https://meta.discourse.org/u/charliel)
#### Post date: [2017年十一月6日 17:27 UTC](https://meta.discourse.org/t/sso-settings-help/73505/3 "2017-11-06T17:27:56Z")

</div>

Might it because once clicking login, users are getting taken to [www.oursite.com/custom-login-page](http://www.oursite.com/custom-login-page), where I can see the redirect\_to in the URL, but then if they’re new they have to click register so then they get taken to [www.oursite.com/custom-login-page/?action=register](http://www.oursite.com/custom-login-page/?action=register), which doesn’t have the redirect\_to in the URL anymore?

PS Not sure what’s going on with the formatting but you need to hover over the links I pasted to see the full paths.

---

<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: [2017年十一月6日 17:38 UTC](https://meta.discourse.org/t/sso-settings-help/73505/4 "2017-11-06T17:38:46Z")

</div>

> [@charliel](#):
>
> Our current issue is that if a new user (not registered on WP) is on Discourse, clicks login then registers through WP, he ends up on our homepage,

Sorry, I didn’t read your question correctly. Yes, that’s the way it works when a user first registers. Ideally, users would register on WordPress before they tried to login to Discourse. I’ll see if I can come up with a workaround for this.

---

<div class="post-metadata">

### Author: ![charliel](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/charliel/32/120555_2.png) [@charliel](https://meta.discourse.org/u/charliel)
#### Post date: [2017年十一月6日 17:49 UTC](https://meta.discourse.org/t/sso-settings-help/73505/5 "2017-11-06T17:49:43Z")

</div>

I see. Yes, it’s because a significant number of our forum users don’t register through WP first. They come straight to the forum. If you could find a workaround that would be great.
