PHPackages                             dvsa/php-govuk-account - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Authentication &amp; Authorization](/categories/authentication)
4. /
5. dvsa/php-govuk-account

ActiveLibrary[Authentication &amp; Authorization](/categories/authentication)

dvsa/php-govuk-account
======================

A league/oauth2-client provider for GOV.UK One Login

v4.0.0(1mo ago)012.3k—2.3%2[2 PRs](https://github.com/dvsa/php-govuk-account/pulls)MITPHPPHP ~8.2.0 || ~8.3.0 || ~8.4.0 || ~8.5.0CI passing

Since Nov 8Pushed 1mo ago6 watchersCompare

[ Source](https://github.com/dvsa/php-govuk-account)[ Packagist](https://packagist.org/packages/dvsa/php-govuk-account)[ RSS](/packages/dvsa-php-govuk-account/feed)WikiDiscussions main Synced 2d ago

READMEChangelog (9)Dependencies (26)Versions (16)Used By (0)

GOV.UK One Login (OAuth2 Provider)
==================================

[](#govuk-one-login-oauth2-provider)

A provider (based on [PHP League OAuth2-Client](https://oauth2-client.thephpleague.com/)) to interact with [GOV.UK Account](https://www.sign-in.service.gov.uk/).

Supports autoconfiguration for most settings using the discovery endpoint.

> For identity assurance (when verifying the JWT in , you will need to define the `identity_assurance_public_key` and `expected_core_identity_issuer` for the short interim until the key and issuer is published on the discovery endpoint.

Installing
----------

[](#installing)

The recommended way to install is through [Composer](https://getcomposer.org/).

```
composer require dvsa/php-govuk-account

```

Configuring
-----------

[](#configuring)

You may want to refer to the documentation provided at [PHP League OAuth2-Client](https://oauth2-client.thephpleague.com/) as this package is a provider for that abstract package.

When instantiating the provider, the constructor accepts **additional** attributes defined in `array $options = []` which are specific for this provider; in addition to the default options provided by the AbstractProvider ([PHP League OAuth2-Client](https://oauth2-client.thephpleague.com/)).

```
'base_uri' => 'https://oidc.integration.account.gov.uk', // Base URI for the GOV.UK One Login API
'discovery_endpoint' => 'https://oidc.integration.account.gov.uk/.well-known/openid-configuration', // Endpoint for OIDC discovery
'core_identity_did_document_url' => 'https://identity.integration.account.gov.uk/.well-known/did.json', // The DID document URL used to verify the JWTCoreIdentity token from UserDetails endpoint
'client_id' => '', // Client ID issued by GOV.UK One Login
'keys' => [
    'algorithm' => 'RS256', // Algorithm for private_key
    'private_key' => '', // Private key used to encode assertion when obtaining access token (public key must be shared with GOV.UK One Login)
    'public_key' => '', // Public key used to decode assertion when obtaining access token
],
'redirect_uri' => [
    'logged_in' => '', // The url used for redirection back to the service
    'logged_out' => '', // The url used for redirection back to the service
],
'expected_core_identity_issuer' => 'https://identity.integration.account.gov.uk/', // Issuer for JWTCoreIdentity token
```

Contributing
------------

[](#contributing)

Please refer to our [Contribution Guide](/CONTRIBUTING.md) and [Contributor Code of Conduct](/CODE_OF_CONDUCT.md).

###  Health Score

56

—

FairBetter than 97% of packages

Maintenance94

Actively maintained with recent releases

Popularity27

Limited adoption so far

Community16

Small or concentrated contributor base

Maturity72

Established project with proven stability

 Bus Factor1

Top contributor holds 81% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~144 days

Recently: every ~197 days

Total

10

Last Release

32d ago

Major Versions

1.0.4 → 2.0.02024-04-04

2.0.1 → 3.0.02024-10-31

3.1.0 → v4.0.02026-06-02

PHP version history (3 changes)1.0.0PHP ^7.4 || ^8.0

2.0.0PHP ^8.2

v4.0.0PHP ~8.2.0 || ~8.3.0 || ~8.4.0 || ~8.5.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/6ac141ec696a70dbc4b8c1c7541cd1bfc06e99617f2484d7631ed43cb48d2f6b?d=identicon)[dvsa](/maintainers/dvsa)

---

Top Contributors

[![jerotire](https://avatars.githubusercontent.com/u/5068769?v=4)](https://github.com/jerotire "jerotire (34 commits)")[![fibble](https://avatars.githubusercontent.com/u/1016567?v=4)](https://github.com/fibble "fibble (3 commits)")[![ilindsay](https://avatars.githubusercontent.com/u/6673081?v=4)](https://github.com/ilindsay "ilindsay (2 commits)")[![JoshuaLicense](https://avatars.githubusercontent.com/u/638172?v=4)](https://github.com/JoshuaLicense "JoshuaLicense (2 commits)")[![sdh100shaun](https://avatars.githubusercontent.com/u/79883?v=4)](https://github.com/sdh100shaun "sdh100shaun (1 commits)")

---

Tags

sdksigninonelogindvsagovuk

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Code StylePHP\_CodeSniffer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/dvsa-php-govuk-account/health.svg)

```
[![Health](https://phpackages.com/badges/dvsa-php-govuk-account/health.svg)](https://phpackages.com/packages/dvsa-php-govuk-account)
```

###  Alternatives

[tempest/framework

The PHP framework that gets out of your way.

2.2k34.4k15](/packages/tempest-framework)[civicrm/civicrm-core

Open source constituent relationship management for non-profits, NGOs and advocacy organizations.

751291.4k43](/packages/civicrm-civicrm-core)[google/auth

Google Auth Library for PHP

1.4k294.2M219](/packages/google-auth)[typo3/cms

TYPO3 CMS is a free open source Content Management Framework initially created by Kasper Skaarhoj and licensed under GNU/GPL.

1.2k1.9M122](/packages/typo3-cms)[drupal/core-recommended

Locked core dependencies; require this project INSTEAD OF drupal/core.

6942.5M421](/packages/drupal-core-recommended)[shopware/core

Shopware platform is the core for all Shopware ecommerce products.

585.6M574](/packages/shopware-core)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
