Integrating a forum with your main website

running Discourse on a subdomain (community.example.com) but want tighter integration with the main site (example.com). SSO, shared navigation, maybe surfacing forum content on the main site. What is the best approach?

Discourse Connect (formerly DiscourseConnect SSO) handles the authentication integration. Your main site becomes the SSO provider and Discourse authenticates against it. Users log in once on the main site and are automatically logged into the forum.

For shared navigation, a custom Discourse theme component that renders the same header as your main site works well. Just embed the HTML/CSS in the theme.

For surfacing forum content on the main site, use the Discourse API to pull recent topics, popular threads, or category-specific content.

if you want to go deeper, consider running Discourse on a subfolder (/forum/) instead of a subdomain. This requires a reverse proxy (nginx or Cloudflare Workers) but gives you better SEO juice since the forum content is under your main domain.

The SSO + subfolder + shared header combo makes the forum feel like a native part of your site rather than a separate platform.

the subfolder approach is interesting. We are already on Cloudflare so the Workers reverse proxy is feasible. Going to prototype the SSO integration first since that is the biggest user experience win.