RealmDeployDocs
Getting started

Your first day

Sign in to the admin console, create a realm, add a test user and connect your first app over OpenID Connect.

Your tenant is standard Keycloak, so every step here is the same as in the Keycloak server administration guide. The examples use auth.example.com; use your own hostname.

Sign in to the admin console

Open https://auth.example.com/admin/ and sign in with the administrator account we handed over. It lives in the master realm, which exists only to manage Keycloak itself.

Then, in the account console (your name, top right, then Manage account):

  • Change the password.
  • Set up two-factor authentication with an authenticator app.

Give every administrator their own account rather than sharing one.

Create a realm for your apps

Keep your users and apps out of master: create a realm for them.

  1. Open the realm selector at the top of the left menu and choose Create realm.
  2. Enter a name, for example example. It becomes part of every URL of the realm, so pick a short one without spaces.
  3. Choose Create.

The realm's OpenID Connect discovery document is now at:

https://auth.example.com/realms/example/.well-known/openid-configuration

Its issuer, which your apps check in every token, is https://auth.example.com/realms/example.

Add a test user

  1. In your new realm, open Users and choose Add user.
  2. Enter a username and choose Create.
  3. On the Credentials tab, choose Set password, turn Temporary off, and save.

The user can sign in at the realm's account console, https://auth.example.com/realms/example/account.

Connect an app

  1. Open Clients and choose Create client.
  2. Leave Client type on OpenID Connect, enter a Client ID (for example my-app) and choose Next.
  3. Set Client authentication:
    • On for an app with a server side that can keep a secret. Keycloak creates a client secret, shown on the client's Credentials tab.
    • Off for a single-page or mobile app. Use the authorization code flow with PKCE.
  4. Keep Standard flow on and choose Next.
  5. Enter your app's Valid redirect URIs (for example https://app.example.com/callback) and, for a browser app, its Web origins (https://app.example.com). Choose Save.

Configure your app's OpenID Connect library with:

SettingValue
Issuer or discovery URLhttps://auth.example.com/realms/example
Client IDmy-app
Client secretFrom the Credentials tab, only when client authentication is on
Redirect URIThe one you entered in step 5

Sign in to your app with the test user. If the redirect fails, Keycloak shows the reason; it is almost always a redirect URI that does not match exactly.

Before you go live

Keycloak's outgoing connections are closed by default. Tell us before you rely on any of these, and we open the connection:

  • Email. Keycloak sends verification and password-reset emails through the SMTP server you set under Realm settings → Email. Tell us its host and port.
  • Outside OpenID Connect identity providers your users sign in with, such as Google or Microsoft Entra ID. Keycloak calls their token endpoint from your tenant. Tell us the provider.
  • LDAP or Active Directory user federation. Tell us the server's address and port.

On this page