ellaisys/aws-cognito

Laravel Authentication using AWS Cognito (Web and API)

Maintainers

Package info

github.com/ellaisys/aws-cognito

Homepage

pkg:composer/ellaisys/aws-cognito

Transparency log

Statistics

Installs: 272 257

Dependents: 1

Suggesters: 0

Stars: 121

Open Issues: 6


README

Laravel Authentication using AWS Cognito - Web and API

Laravel Authentication using AWS Cognito

Note

Last Updated: 2026-07-31

Release Version  Release Date  Total Downloads 

GitHub Stars  GitHub Forks  GitHub Contributors  APM

Quality Gate Status  Security Rating  Maintainability Rating

Contents

Introduction

This package provides native integration between Laravel's authentication system and Amazon Cognito. It supports session-based authentication for web applications, token-based authentication for APIs, Multi-Factor Authentication (MFA), SRP authentication, Passkeys (FIDO2/WebAuthn), and Device Authentication while allowing developers to continue using Laravel's familiar authentication features.

It integrates AWS Cognito into Laravel's authentication ecosystem while preserving Laravel's native authentication experience.

This is built on top of the AWS Cognito SDK for PHP, to provide a simple and easy-to-use experience for interacting with the AWS Cognito service. The package provides a set of traits that can be used in your Laravel controllers to handle all the authentication-related features.

Demo Application & Code

A complete demo application is available that demonstrates the package in a real Laravel application. It can be used as a reference implementation or as a starting point for your own projects.

The demo application code is available on the GitHub and can be used as a reference for your own application.

Compatibility

PHP SupportLaravel Support
Version Support
7.4 Yes ✔️
8.0 Yes ✔️
8.1 Yes ✔️
8.2 Yes ✔️
8.3 NA
8.4 NA
Version Support
7.x Yes ✔️
8.x Yes ✔️
9.x Yes ✔️
10.x Yes ✔️
11.x Yes ✔️
12.x Yes ✔️
13.x NA

Features

Architecture and Design

The following diagram illustrates the high level architecture and design of this package, highlighting its integration with Laravel's authentication system and AWS Cognito services.

Laravel Authentication using AWS Cognito - Architecture and Design

Installation

This package is available via Packagist and can be installed using composer.

composer require ellaisys/aws-cognito

Code Quality

This project follows secure coding and quality assurance practices throughout its development lifecycle. Automated static analysis is performed using SonarCloud to identify potential bugs, vulnerabilities, maintainability issues, and code smells before changes are merged.

In addition to automated analysis, all contributions are reviewed before being merged to help maintain the quality, reliability, and security of the project.

Changelog

For a complete history of changes, improvements, bug fixes, and new features, please refer to the CHANGELOG.md.

Security

The security of this project and its users is important to us. If you discover or suspect a security vulnerability, please follow our responsible disclosure process described in SECURITY.md.

We kindly ask that you do not report security vulnerabilities through public GitHub issues.

Roadmap

Our development roadmap, planned features, and future enhancements are maintained on the project's GitHub Projects and Wiki.

Credits & Contributors

This project has been inspired by the work of the open-source community. We are grateful to the developers and maintainers whose ideas, discussions, libraries, and code have helped influence the design and implementation of this package.

We would like to acknowledge the following projects and organizations for their inspiration, technical references, or contributions. Portions of this project were adapted from the following open-source projects in accordance with their respective licenses:

Special thanks to everyone who has contributed their time, expertise, and feedback to help improve this project.

Contribute

Open source thrives because of its community. Whether you're fixing bugs, improving documentation, reviewing code, suggesting new features, or helping other users, every contribution is valued and appreciated.

If you'd like to get involved, explore the contribution badges below to find ways you can help.

GitHub repo Issues  GitHub repo Good Issues for newbies  GitHub Help Wanted issues
GitHub repo PRs  GitHub repo Merged PRs  GitHub Help Wanted PRs

Support Us

EllaiSys was a web engineering and technology consulting company specializing in Cloud Computing (AWS and Azure), DevOps, Identity and Access Management (IAM), and Product Engineering. Although we concluded our professional services business in October 2021, we remain committed to maintaining and improving our open-source projects for the benefit of the community.

If this project has been helpful to you or your organization, we'd love your support. There are several ways you can contribute:

  • Give some love by starring the repository on GitHub, sharing it with your network, or recommending it to others.
  • Spread the word by writing blog posts, creating tutorials, or giving talks about the project.
  • Contribute code by fixing bugs, implementing new features, or improving performance.
  • Report issues and help us identify bugs or edge cases.
  • Improve the documentation by correcting errors, adding examples, or enhancing clarity.
  • Share ideas by suggesting new features or improvements.
  • Help others by answering questions and participating in community discussions.
  • Spread the word by starring the repository, sharing it with your network, or recommending it to others.

Sponsor the Project

Maintaining a high-quality open-source project requires a significant investment of time and effort. If you'd like to support its continued development financially, your sponsorship is greatly appreciated. Every contribution—regardless of size—helps us dedicate more time to maintaining the project, fixing issues, implementing new features, and improving the documentation.

Whether you contribute your time, expertise, or financial support, thank you for helping us build better software for the community.

License

This package is open-source software released under the MIT License.

The source code is available on GitHub and may be used, copied, modified, merged, published, distributed, sublicensed, and/or sold in accordance with the terms of the MIT License.

A copy of the license is included with this package in the License file. Please review the license before using, modifying, or redistributing this software.

Disclaimer

This package is actively maintained and continuously improved.

We welcome bug reports, feature requests, and other feedback from the community. While we will make every reasonable effort to review and address reported issues, support is provided on a voluntary, best-effort basis. As this is an open-source project offered free of charge, we are unable to guarantee response times, issue resolution, or support service level agreements (SLAs).