Discourse to discourse SSO

AI-generated summary

The discussion revolves around enabling Single Sign-On (SSO) between multiple Discourse forums, allowing users to log in across instances without creating separate accounts. itsbhanusharma initiated the conversation, asking if Discourse SSO can treat other Discourse instances as clients. riking confirmed that enabling “sso provider” on a primary forum allows this. However, itsbhanusharma clarified the need for mutual user syncing between forums with separate user bases. pfaffman cautioned that SSO is “all or nothing” and suggested using social logins instead, or manually migrating users via category import/export — though this requires users to have posted at least once. itsbhanusharma asked if local logins can sync to an SSO server; pfaffman explained that users from secondary forums must be manually created on the primary SSO server, and offered custom development via Marketplace or personal contact. icaria36 proposed a bold idea: using meta.discourse.org login as a universal social login for all Discourse instances, enabling a single sign-on across the entire ecosystem. riking referenced past discussions in #discourse_hub, hinting at prior exploration of unified user identities. The thread highlights technical limitations of native SSO for bidirectional syncing and suggests workarounds or custom development for cross-forum user integration.

I’ve been discussing this idea with one of my colleagues who also happens to be running a forum on discourse about the possibility to allow the users of one forum to sign in to the other forum without having to create a new account.

I couldn’t find anyone doing this so I wanted to ask if discourse SSO is capable of allowing other discourse instances as a client?

2 Likes

Yes, just enable “sso provider” on the “primary” forum that you expect everyone to have an account on.

2 Likes

I had thought of that, I’ll give it a shot but It’s more like a mutual thing, We have separate user base on both forums, Will it be possible to sync users of all the secondary forum to the primary forum?

The problem with SSO, as I think you’ve realized, is that it’s all it nothing. You’re likely better if just using social logins.

If you do want to have both sites share a single user database you’ll need to pull over the users. There’s not an easy way to do that that I am aware of. One solution might be to use category export /import, which would create the users (and then you’d hide or delete the imported categories). You’d need to know that everyone had posted at least once.

1 Like

So basically local logins can’t be synced to the SSO server?

If you want server B to use server A as the SSO master, you’d need to create all of B’s users on A. I’m not aware of a script that does that.

There are a couple ways I could imagine doing it. If you’ve got a budget post in Marketplace or see my contact info in my profile.

I haven’t thought of a budget yet but I’d get in touch to discuss the possibilities…

1 Like

Would it be a crazy idea to offer https://meta.discourse.org login as a social login for other Discourse instances (enabling this social login)? Imagine, a login for all Discourse instances.

1 Like

Take a look at the old #discourse_hub topics: Unique user names in Discourse Hub

5 Likes