# How to Integrate Keycloak for Authentication with Apache APISIX

DevFeed: [How to Integrate Keycloak for Authentication with Apache APISIX](<https://devfeed.tech/articles/how-to-integrate-keycloak-for-authentication-with-apache-apisix-31589.md>)

Original publisher: [Read original article](<https://www.keycloak.org/2021/12/apisix>)

Author: Xinxin Zhu & Yilin Zeng

Published: 2021-12-21T00:00:00Z

Content type: tutorial

Language: en

Sources: [Keycloak Blog](<https://devfeed.tech/sources/keycloak-blog.md>)

Topics: [Keycloak](<https://devfeed.tech/topics/keycloak.md>), [Authentication](<https://devfeed.tech/topics/authentication.md>), [gateway](<https://devfeed.tech/topics/gateway.md>), [API](<https://devfeed.tech/topics/api.md>), [openid](<https://devfeed.tech/topics/openid.md>), [OAuth 2.0](<https://devfeed.tech/topics/oauth2.md>)

Tags: [api-gateway](<https://devfeed.tech/tags/api-gateway.md>), [authentication](<https://devfeed.tech/tags/authentication.md>), [how-to](<https://devfeed.tech/tags/how-to.md>), [idm](<https://devfeed.tech/tags/idm.md>), [kerberos](<https://devfeed.tech/tags/kerberos.md>), [keycloak](<https://devfeed.tech/tags/keycloak.md>), [ldap](<https://devfeed.tech/tags/ldap.md>), [oauth-2-0](<https://devfeed.tech/tags/oauth-2-0.md>), [open-source](<https://devfeed.tech/tags/open-source.md>), [openid-connect](<https://devfeed.tech/tags/openid-connect.md>), [saml](<https://devfeed.tech/tags/saml.md>), [sso](<https://devfeed.tech/tags/sso.md>)

## AI overview

A tutorial explains how to use Keycloak with Apache APISIX for centralized authentication through OpenID Connect. It covers Keycloak capabilities, APISIX's OpenID Connect plugin, required dependencies, and installation steps for several operating systems, Docker, and Helm.

## Source excerpt

This article shows you how to use OpenID-Connect protocol and Keycloak for identity authentication in Apache APISIX through detailed steps. Keycloak is an open source identity and access management solution for modern applications and services. Keycloak supports Single-Sign On, which enables services to interface with Keycloak through protocols such as OpenID Connect, OAuth 2.0, etc. Keycloak also supports integrations with different authentication services, such as Github, Google and Facebook. In addition, Keycloak also supports user federation, and can import users through LDAP and Kerberos. For more information about Keycloak, please refer to the official documentation. Apache APISIX is a dynamic, real-time, high-performance API gateway, providing rich traffic management. The project offers load balancing, dynamic upstream, canary release, circuit breaking, authentication, observability, and many useful plugins. In addition, the gateway supports dynamic plugin changes along with hot update. The OpenID Connect plugin for Apache APISIX allows users to replace traditional authentication mode with centralized identity authentication mode via OpenID Connect. How to use Install Apache APISIX Install dependencies The Apache APISIX runtime environment requires dependencies on NGINX and etcd. Before installing Apache APISIX, please install dependencies according to the operating system you are using. We provide the dependencies installation instructions for CentOS7, Fedora 31 and 32, Ubuntu 16.04 and 18.04, Debian 9 and 10, and macOS. Please refer to Install Dependencies for more details. Installation via RPM Package (CentOS 7) This installation method is suitable for CentOS 7; please run the following command to install Apache APISIX. sudo yum install -y https://github.com/apache/apisix/releases/download/2.7/apisix-2.7-0.x86_64.rpm Installation via Docker Please refer to Installing Apache APISIX with Docker. Installation via Helm Chart Please refer to Installing Apache A