Overview
Casdoor allows for the use of other OAuth applications as a sign-in method.
Currently, Casdoor supports multiple OAuth application providers. The icons of these providers will be displayed on the login and signup pages once they have been added to Casdoor. The following are the providers that Casdoor supports:
| Provider | Logo | Provider | Logo | Provider | Logo | Provider | Logo |
|---|---|---|---|---|---|---|---|
| ADFS | Alipay | Amazon | Apple | ||||
| Auth0 | Azure AD | Azure AD B2C | Baidu | ||||
| Bilibili | Bitbucket | Box | Casdoor | ||||
| Cloud Foundry | Dailymotion | Deezer | DigitalOcean | ||||
| DingTalk | Discord | Tiktok | Dropbox | ||||
| Eve Online | Fitbit | Gitea | |||||
| Gitee | GitHub | GitLab | |||||
| Heroku | InfluxCloud | Infoflow | |||||
| Intercom | Kakao | Lark | Lastfm | ||||
| Line | Mailru | Meetup | |||||
| Microsoft | Naver | Nextcloud | Okta | ||||
| OneDrive | Oura | Patreon | PayPal | ||||
| Salesforce | Shopify | Slack | |||||
| SoundCloud | Spotify | Steam | Strava | ||||
| Stripe | TikTok | Tumblr | Twitch | ||||
| Typetalk | Uber | VK | |||||
| WeCom | WePay | ||||||
| Xero | Yahoo | Yammer | Yandex | ||||
| Zoom | SMS | Battle.net |
We will show you how to apply for a third-party service and add it to Casdoor.
Apply to become a developer
Before this, there are some general concepts you need to understand.
- RedirectUrl, Redirect address after authentication, fill in your application address, such as
https://forum.casbin.com/ - Scope, Permission granted to you by the user, such as basic profile, Email address and posts and others.
- ClientId/AppId, ClientKey/AppSecret, This is the most important information, and it is what you need to get after you apply for a developer account. You can not share the key/secret with anyone.
Add an OAuth provider
- Go to your Casdoor index page.
- Click on
Providersin the top bar. - Click on
Add, and you will see a new provider added to the list at the top. - Click on the new provider to make changes to it.
- In the
Categorysection, selectOAuth. - Choose the specific OAuth provider that you require from the
Typedropdown. - Fill in the necessary information, such as
Client IDandClient Secret.
User Field Mapping
OAuth providers often return additional user information beyond the standard profile fields. Casdoor's User Mapping feature allows you to automatically populate user profile fields from OAuth claims returned by your identity provider. This is particularly useful when integrating with enterprise identity providers like Okta, Azure AD, or other custom OAuth services that provide rich user metadata.
Automatic Account Linking
When users authenticate via OAuth, Casdoor automatically attempts to link accounts using multiple strategies: existing OAuth links, email/phone matching (if enabled), and case-insensitive username matching. This is particularly useful for enterprises with existing users who want to enable OAuth authentication without requiring manual account linking.
Application Setup
- Click on
Applicationin the top bar and select the desired application to edit. - Click on the provider add button and choose the newly added provider.
- Modify the provider's permissions, such as enabling registration, login, and unbinding.
- You're all set!