Free sso

Create Free SSO with Keycloak

Create a Free SSO System with Keycloak

Want to add Single Sign-On (SSO) to your apps without paying for enterprise tools? You can do this completely free using Keycloak — a powerful open-source identity and access management solution.

🔧 What You'll Learn

  • How to run Keycloak locally
  • Set up users and clients
  • Use SSO to authenticate in ASP.NET or any app

🚀 Step 1: Run Keycloak Locally

You can run Keycloak using Docker in development:

docker run -p 8080:8080 \
  -e KEYCLOAK_ADMIN=admin \
  -e KEYCLOAK_ADMIN_PASSWORD=admin \
  quay.io/keycloak/keycloak:24.0.1 start-dev

Then go to http://localhost:8080 and log in with:

  • Username: admin
  • Password: admin

🔐 Step 2: Set Up Realm, Client, and Users

Create a Realm

A realm is like a project or tenant. Go to the top-left menu and click “Create Realm”.

Create a Client

  1. In your realm, go to ClientsCreate Client
  2. Client ID: myclient
  3. Client Type: OpenID Connect
  4. Root URL / Redirect URI: https://localhost:5001/signin-oidc (or your app URL)

Create a User

  1. Go to UsersAdd user
  2. Set username and email
  3. Go to Credentials tab → set a password and enable it

⚙️ Step 3: Connect Your App

In your ASP.NET or Node.js app, use the following settings for OpenID Connect login:

  • Authority: http://localhost:8080/realms/myrealm
  • ClientId: myclient
  • ResponseType: code or id_token token

This lets your app redirect users to Keycloak to log in, and get back a secure JWT token you can use to call APIs.

✅ Result

You now have a completely free SSO system using Keycloak! You can manage users, secure APIs, and connect multiple apps using industry-standard protocols like OpenID Connect and OAuth 2.0.

📚 Resources

Written by ChatGPT – June 2025

Comments

Popular posts from this blog

SSO

Best Free SSO Options