npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@aartoni/strapi-plugin-oidc

v1.2.0

Published

Replace the Strapi 5 admin login with your OIDC provider

Readme

strapi-plugin-oidc

npm version license

Single sign-on for Strapi 5! Log in to the administration screen using an OpenID Connect (OIDC) provider.

Optionally overwrites Strapi's default admin login page and endpoints.

Installation

yarn add @aartoni/strapi-plugin-oidc

or

npm i @aartoni/strapi-plugin-oidc

Configuration

With OIDC Discovery (recommended: the plugin auto-resolves endpoints from your provider):

export default ({ env }) => ({
  "oidc": {
    enabled: true,
    config: {
      issuer: "https://your-oidc-provider.com",
      clientId: "[Client ID from the provider]",
      clientSecret: "[Client secret from the provider]",
      redirectUri: "https://your-strapi/api/oidc/callback",
      scopes: "openid profile email groups",
    },
  },
});

Full options

Discoverable options are only required when discovery is false.

| Key | Required | Default | Description | |---|---|---|---| | issuer | yes | – | Provider issuer URL (used for discovery and id_token validation) | | discovery | no | true | Enable OIDC Discovery | | clientId | yes | – | OIDC client ID | | clientSecret | yes | – | OIDC client secret | | redirectUri | yes | – | Callback URL after login | | scopes | no | "openid profile email groups" | Space-separated OIDC scopes | | authorizationEndpoint | discoverable | – | Provider authorization endpoint | | tokenEndpoint | discoverable | – | Provider token endpoint | | userInfoEndpoint | discoverable | – | Provider userinfo endpoint | | jwksUri | discoverable | – | Provider JWKS URI | | familyNameField | no | "family_name" | Userinfo claim for last name | | givenNameField | no | "given_name" | Userinfo claim for first name | | rememberMe | no | true | Store JWT in localStorage (true) or cookie (false) |

Optional routing

To overwrite Strapi's default admin login page, you'll have to add an explicit Vite configuration and import the provided plugin.

import { oidcAuthPagePlugin } from '@aartoni/strapi-plugin-oidc/vite';
import { mergeConfig } from 'vite';

export default (config) =>
  mergeConfig(config, { plugins: [oidcAuthPagePlugin()] });

However, this is not enough to guarantee that your Strapi users won't try to login via API. To address that concern, you should load the provided middleware in your config/middlewares.ts.

// Default Strapi middleware stack, plus the native-auth blocker.
export default [
  "strapi::logger",
  "strapi::errors",
  "strapi::security",
  "strapi::cors",
  // ...
  "plugin::oidc.block-native-auth",
];

Add after the default stack, placing it earlier can block admin panel routes.

Role mapping

Admin roles can be mapped from OIDC claims using JMESPath expressions. You can edit the expression from this plugin's page in the admin sidebar, but no user can log in until one is set, so bootstrap an initial expression in src/index.ts (or equivalent) before first startup. See playground/src/index.ts for a working example.

OIDC provider

See the Docker compose file for an example of how to set-up Authelia as an OIDC provider.

Commercial providers might ship OIDC support, including:

Development

See CONTRIBUTING.md.