> For the complete documentation index, see [llms.txt](https://docs.authgear.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.authgear.com/authentication-and-access/social-enterprise-login-providers/social-login-providers/linkedin.md).

# Connect Apps to LinkedIn

Guide on how to add LinkedIn as a social login provider

## Prerequisite

* A LinkedIn Developer profile. You can create one on the [LinkedIn Developers Portal](https://developer.linkedin.com/).
* LinkedIn App

### Step 1: Create a LinkedIn App

Log in to the [LinkedIn Developers Portal](https://developer.linkedin.com/) and create a new app or update the configuration for an existing one.

Go to the **Auth** tab of your LinkedIn app and take note of the "Client ID" and "Client Secret".

Also, add `https://<YOUR_AUTHGEAR_ENDPOINT>/sso/oauth2/callback/linkedin` to "Authorized redirect URLs" under "OAuth 2.0 settings" section.

<figure><img src="https://2638622528-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MAjXpMovvVxeIY33s_K%2Fuploads%2Fgit-blob-83117ddaf434186f28bd16eebb28a5240f8df215%2Flinkedin-social-login-auth-tab.png?alt=media" alt=""><figcaption><p>LinkedIn app, "Auth" tab</p></figcaption></figure>

{% hint style="info" %}
The redirect URI has the form of `/sso/oauth2/callback/:oauth_provider_alias`. The `oauth_provider_alias` is the OAuth Provider Alias configured for this provider in Authgear Portal
{% endhint %}

Next, open the **Products** tab of your LinkedIn app, and request access to "Sign In with LinkedIn using OpenID Connect."

<figure><img src="https://2638622528-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MAjXpMovvVxeIY33s_K%2Fuploads%2Fgit-blob-c8269163d4a6a69af0da7d65199eb0af324bb9cb%2Flinkedin-enable-oidc.png?alt=media" alt=""><figcaption><p>LinkedIn app product list</p></figcaption></figure>

### Step 2: Configure Sign in with LinkedIn through the portal

In the Authgear Portal, go to **Authentication** > **Social / Enterprise Login**.

Enable **Sign in with LinkedIn**.

Then fill in the **Client ID**. and **Client Secret** from your LinkedIn app.

**Save** the settings.

🎉 Done! You have just added LinkedIn Login to your apps!


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.authgear.com/authentication-and-access/social-enterprise-login-providers/social-login-providers/linkedin.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
