PHPackages                             workos/workos-php - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. workos/workos-php

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

workos/workos-php
=================

WorkOS PHP Library

4.32.0(2mo ago)392.4M—0.4%18[4 issues](https://github.com/workos/workos-php/issues)[12 PRs](https://github.com/workos/workos-php/pulls)4MITPHPPHP &gt;=7.3.0CI passing

Since Apr 7Pushed 1mo ago19 watchersCompare

[ Source](https://github.com/workos/workos-php)[ Packagist](https://packagist.org/packages/workos/workos-php)[ Docs](https://workos.com)[ RSS](/packages/workos-workos-php/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (10)Dependencies (6)Versions (105)Used By (4)

WorkOS PHP Library
==================

[](#workos-php-library)

[![Packagist Version](https://camo.githubusercontent.com/4adb5370a9dd5c3ba9ba1ea295546ca5d947adca46b2b259f2445a2e67a12108/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f776f726b6f732f776f726b6f732d706870)](https://camo.githubusercontent.com/4adb5370a9dd5c3ba9ba1ea295546ca5d947adca46b2b259f2445a2e67a12108/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f776f726b6f732f776f726b6f732d706870)[![CI](https://github.com/workos/workos-php/actions/workflows/ci.yml/badge.svg?branch=main)](https://github.com/workos/workos-php/actions/workflows/ci.yml)

The WorkOS library for PHP provides convenient access to the WorkOS API from applications written in PHP.

Documentation
-------------

[](#documentation)

See the [API Reference](https://workos.com/docs/reference/client-libraries) for PHP usage examples.

Installation
------------

[](#installation)

To install via composer, run the following:

```
composer require workos/workos-php

```

Configuration
-------------

[](#configuration)

The package will need to be configured with your [API Key](https://dashboard.workos.com/api-keys) and [Client ID](https://dashboard.workos.com/configuration). By default, the packages looks for a `WORKOS_API_KEY` and `WORKOS_CLIENT_ID` environment variable.

SDK Versioning
--------------

[](#sdk-versioning)

For our SDKs WorkOS follows a Semantic Versioning ([SemVer](https://semver.org/)) process where all releases will have a version X.Y.Z (like 1.0.0) pattern wherein Z would be a bug fix (e.g., 1.0.1), Y would be a minor release (1.1.0) and X would be a major release (2.0.0). We permit any breaking changes to only be released in major versions and strongly recommend reading changelogs before making any major version upgrades.

Beta Releases
-------------

[](#beta-releases)

WorkOS has features in Beta that can be accessed via Beta releases. We would love for you to try these and share feedback with us before these features reach general availability (GA). To install a Beta version, please follow the [installation steps](#installation) above using the Beta release version.

> Note: there can be breaking changes between Beta versions. Therefore, we recommend pinning the package version to a specific version. This way you can install the same version each time without breaking changes unless you are intentionally looking for the latest Beta version.

We highly recommend keeping an eye on when the Beta feature you are interested in goes from Beta to stable so that you can move to using the stable version.

More Information
----------------

[](#more-information)

- [Single Sign-On Guide](https://workos.com/docs/sso/guide)
- [Directory Sync Guide](https://workos.com/docs/directory-sync/guide)
- [Admin Portal Guide](https://workos.com/docs/admin-portal/guide)
- [Magic Link Guide](https://workos.com/docs/magic-link/guide)

###  Health Score

64

—

FairBetter than 99% of packages

Maintenance87

Actively maintained with recent releases

Popularity55

Moderate usage in the ecosystem

Community35

Small or concentrated contributor base

Maturity67

Established project with proven stability

 Bus Factor6

6 contributors hold 50%+ of commits

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 ~26 days

Total

82

Last Release

70d ago

Major Versions

v0.9.6 → v1.0.02021-05-12

v1.19.0 → v2.0.02022-11-17

v2.1.0 → v3.0.02023-02-02

v3.x-dev → v4.0.02023-11-22

PHP version history (2 changes)v0.0.1PHP &gt;=5.6.0

v3.0.0PHP &gt;=7.3.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/bb9f121082ccf48409fa78d0ae2ccdaafa0a41b360e1866c95ae63e019f897cf?d=identicon)[workos](/maintainers/workos)

---

Top Contributors

[![sheldon-workos](https://avatars.githubusercontent.com/u/243190984?v=4)](https://github.com/sheldon-workos "sheldon-workos (50 commits)")[![jbvolta](https://avatars.githubusercontent.com/u/141062225?v=4)](https://github.com/jbvolta "jbvolta (24 commits)")[![maxdeviant](https://avatars.githubusercontent.com/u/1486634?v=4)](https://github.com/maxdeviant "maxdeviant (15 commits)")[![blairworkos](https://avatars.githubusercontent.com/u/74257063?v=4)](https://github.com/blairworkos "blairworkos (13 commits)")[![mattgd](https://avatars.githubusercontent.com/u/9063128?v=4)](https://github.com/mattgd "mattgd (12 commits)")[![mthadley](https://avatars.githubusercontent.com/u/2635560?v=4)](https://github.com/mthadley "mthadley (11 commits)")[![jthodge](https://avatars.githubusercontent.com/u/17075617?v=4)](https://github.com/jthodge "jthodge (8 commits)")[![willmanduffy](https://avatars.githubusercontent.com/u/782252?v=4)](https://github.com/willmanduffy "willmanduffy (8 commits)")[![workos-sdk-automation[bot]](https://avatars.githubusercontent.com/u/47638084?v=4)](https://github.com/workos-sdk-automation[bot] "workos-sdk-automation[bot] (7 commits)")[![awolfden](https://avatars.githubusercontent.com/u/47123183?v=4)](https://github.com/awolfden "awolfden (7 commits)")[![renovate[bot]](https://avatars.githubusercontent.com/in/2740?v=4)](https://github.com/renovate[bot] "renovate[bot] (7 commits)")[![csrbarber](https://avatars.githubusercontent.com/u/29511995?v=4)](https://github.com/csrbarber "csrbarber (5 commits)")[![hadihallak](https://avatars.githubusercontent.com/u/13556017?v=4)](https://github.com/hadihallak "hadihallak (5 commits)")[![robframpton](https://avatars.githubusercontent.com/u/2466445?v=4)](https://github.com/robframpton "robframpton (5 commits)")[![adamzinder](https://avatars.githubusercontent.com/u/96083517?v=4)](https://github.com/adamzinder "adamzinder (5 commits)")[![blobaugh](https://avatars.githubusercontent.com/u/806179?v=4)](https://github.com/blobaugh "blobaugh (5 commits)")[![kendallstrautman](https://avatars.githubusercontent.com/u/36613477?v=4)](https://github.com/kendallstrautman "kendallstrautman (5 commits)")[![nicknisi](https://avatars.githubusercontent.com/u/293805?v=4)](https://github.com/nicknisi "nicknisi (4 commits)")[![henrylamchan](https://avatars.githubusercontent.com/u/19150308?v=4)](https://github.com/henrylamchan "henrylamchan (4 commits)")[![PaulAsjes](https://avatars.githubusercontent.com/u/108872335?v=4)](https://github.com/PaulAsjes "PaulAsjes (4 commits)")

---

Tags

adfsaudit-logsdirectory-syncgsuite-saml-appsoktaphp-sdksamlscimssosso-authentication

###  Code Quality

TestsPHPUnit

Code StylePHP CS Fixer

### Embed Badge

![Health badge](/badges/workos-workos-php/health.svg)

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

###  Alternatives

[label84/laravel-hours-helper

Creates a Collection of times with a given interval.

27591.2k](/packages/label84-laravel-hours-helper)

PHPackages © 2026

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