Plus One for Craft CMS

Plus One is a Craft 6 plugin. Craft 6 is still in beta, and so is Plus One (6.0.0-beta.1) — try it on staging first and use caution on production sites.

Craft 6 · Beta — use caution on production

Social sign-in, done carefully

Craft 6 can already sign people in with OAuth — from a config file. Plus One puts the providers in the control panel, adds every SocialiteProviders package and any OpenID Connect provider, gives your Twig and Blade templates sign-in buttons and connected accounts, and makes sure an email address from a provider never hands over somebody else's account.

Plus One

Buttons and accounts, in Twig or Blade

One API for both of Craft 6's template engines. Return paths are checked to stay on your site; connecting asks for the user's password when they have one; the last way to sign in can't be disconnected.

twig
{# Twig: sign-in buttons #}
{{ plusone.buttons('/account') }}

{# Twig: connected accounts #}
{% for a in plusone.accounts() %}
  {{ a.name }}
  {{ a.connected ? plusone.disconnectForm(a.handle) : plusone.connectForm(a.handle) }}
{% endfor %}

{{-- Blade --}}
{{ $plusone->buttons('/account') }}
@foreach ($plusone->accounts() as $a) {{ $a['name'] }} @endforeach

Features

Craft's own OAuth service does the signing in. Plus One manages it and keeps it safe.

Providers in the control panel

Add Google, GitHub, GitLab, Facebook, LinkedIn, Slack and more from Settings. Client secrets are environment variable references — never stored in project config, never shown back.

Every SocialiteProviders package

composer require any of 100+ SocialiteProviders packages and it appears in the provider menu with its own settings. No service provider or event listener to write.

Any OpenID Connect provider

Authentik, Keycloak, Zitadel, Auth0, Okta or your company's SSO: paste three endpoint URLs and it's a provider.

Account-takeover guards

An unverified email never links to an existing account, matching by a verified email is opt-in per provider, and admins are off by default (Craft skips two-step verification for social sign-in).

  • state on every provider and PKCE by default
  • Only on-site return URLs
  • No lockouts: the last way to sign in can't be disconnected

Registration rules

Require a verified email, allow only certain email domains, put new users in a default group, and decide per provider whether it may register anyone at all.

Per site and headless

Choose which providers each site offers, with a callback URL per site — even for sites under a path like /fr/. A plusOneProviders GraphQL query gives headless login pages their buttons, and nothing else.

Frequently Asked Questions

The questions worth answering before you install it.

Try it on staging today

Plus One is free (it needs Craft Pro). It's a Craft 6 beta plugin on a beta CMS — start on a development or staging site and use caution on production.

More plugins

Pairs well with Plus One