PHPackages                             aws/aws-sdk-php-laravel - 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. [File &amp; Storage](/categories/file-storage)
4. /
5. aws/aws-sdk-php-laravel

ActiveLibrary[File &amp; Storage](/categories/file-storage)

aws/aws-sdk-php-laravel
=======================

A simple Laravel 9/10/11/12/13 service provider for including the AWS SDK for PHP.

3.11.0(1mo ago)1.7k35.6M—1.6%251[3 issues](https://github.com/aws/aws-sdk-php-laravel/issues)[1 PRs](https://github.com/aws/aws-sdk-php-laravel/pulls)20Apache-2.0PHPPHP &gt;=8.1CI passing

Since Feb 14Pushed 1mo ago78 watchersCompare

[ Source](https://github.com/aws/aws-sdk-php-laravel)[ Packagist](https://packagist.org/packages/aws/aws-sdk-php-laravel)[ Docs](https://aws.amazon.com/sdk-for-php/)[ RSS](/packages/aws-aws-sdk-php-laravel/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (10)Dependencies (10)Versions (38)Used By (20)

AWS Service Provider for Laravel 9 - 13
=======================================

[](#aws-service-provider-for-laravel-9---13)

[![Latest Stable Version](https://camo.githubusercontent.com/af566fcf798b6cdbf8def55a7c7c193846b376ed9c7ee48d3d68281f4f1b1a5d/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6177732f6177732d73646b2d7068702d6c61726176656c2e737667)](https://packagist.org/packages/aws/aws-sdk-php-laravel)[![Total Downloads](https://camo.githubusercontent.com/4861eb3806df7207ff75267d9fceac0fe8eccb5deab3e49c1f05468c79ea98a4/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6177732f6177732d73646b2d7068702d6c61726176656c2e737667)](https://packagist.org/packages/aws/aws-sdk-php-laravel)[![Gitter](https://camo.githubusercontent.com/abe08b740a4156153736f791393ec4da6619c4be73212e75769f52edacc0e2b5/68747470733a2f2f6261646765732e6769747465722e696d2f4a6f696e253230436861742e737667)](https://gitter.im/aws/aws-sdk-php?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge)

This is a simple [Laravel](http://laravel.com/) service provider for making it easy to include the official [AWS SDK for PHP](https://github.com/aws/aws-sdk-php) in your Laravel and Lumen applications.

This README is for version 3.x of the service provider, which is implemented to work with Version 3 of the AWS SDK for PHP and Laravel 9-13.

**Major Versions:**

- **3.x** (YOU ARE HERE) - For `laravel/framework:9.0|10.0|11.0|12.0|13.0` and `aws/aws-sdk-php:^3.338.0`
- **2.x** ([2.0 branch](https://github.com/aws/aws-sdk-php-laravel/tree/2.0)) - For `laravel/framework:5.0.*` and `aws/aws-sdk-php:~2.4`
- **1.x** ([1.0 branch](https://github.com/aws/aws-sdk-php-laravel/tree/1.0)) - For `laravel/framework:4.*` and `aws/aws-sdk-php:~2.4`

Jump To:

- [Getting Started](#Getting-Started)
- [Getting Help](#Getting-Help)
- [Contributing](#Contributing)
- [More Resources](#Resources)

Getting Started
---------------

[](#getting-started)

### Installation

[](#installation)

The AWS Service Provider can be installed via [Composer](http://getcomposer.org) by requiring the `aws/aws-sdk-php-laravel` package in your project's `composer.json`.

```
{
    "require": {
        "aws/aws-sdk-php-laravel": "~3.0"
    }
}
```

Then run a composer update

```
php composer.phar update
```

To use the AWS Service Provider, you must register the provider when bootstrapping your application.

#### Lumen

[](#lumen)

In Lumen find the `Register Service Providers` in your `bootstrap/app.php` and register the AWS Service Provider.

```
    $app->register(Aws\Laravel\AwsServiceProvider::class);
```

#### Laravel

[](#laravel)

In Laravel find the `providers` key in your `config/app.php` and register the AWS Service Provider.

```
    'providers' => array(
        // ...
        Aws\Laravel\AwsServiceProvider::class,
    )
```

Find the `aliases` key in your `config/app.php` and add the AWS facade alias.

```
    'aliases' => array(
        // ...
        'AWS' => Aws\Laravel\AwsFacade::class,
    )
```

### Configuration

[](#configuration)

By default, the package uses the following environment variables to auto-configure the plugin without modification:

```
AWS_ACCESS_KEY_ID
AWS_SECRET_ACCESS_KEY
AWS_REGION (default = us-east-1)

```

To customize the configuration file, publish the package configuration using Artisan.

```
php artisan vendor:publish  --provider="Aws\Laravel\AwsServiceProvider"
```

The settings can be found in the generated `config/aws.php` configuration file. By default, the credentials and region settings will pull from your `.env` file.

```
return [
    'credentials' => [
        'key'    => env('AWS_ACCESS_KEY_ID', ''),
        'secret' => env('AWS_SECRET_ACCESS_KEY', ''),
    ],
    'region' => env('AWS_REGION', 'us-east-1'),
    'version' => 'latest',
    // You can override settings for specific services
    'Ses' => [
        'region' => 'us-east-1',
    ],
];
```

Note that you can always delete the `credentials` line from this file if you'd like to use the [default SDK Configuration Provider chain](https://docs.aws.amazon.com/sdk-for-php/v3/developer-guide/guide_credentials.html#default-credential-chain) instead.

Referring Laravel 5.2.0 [Upgrade guide](https://laravel.com/docs/5.2/upgrade#upgrade-5.2.0), you must using config file instead of environment variable option if using php artisan `config:cache`.

Learn more about [configuring the SDK](http://docs.aws.amazon.com/aws-sdk-php/v3/guide/guide/configuration.html) on the SDK's User Guide.

### Usage

[](#usage)

In order to use the AWS SDK for PHP within your app, you need to retrieve it from the [Laravel Service Container](https://laravel.com/docs/container#binding). The following example uses the Amazon S3 client to upload a file.

```
$s3 = App::make('aws')->createClient('s3');
$s3->putObject(array(
    'Bucket'     => 'YOUR_BUCKET',
    'Key'        => 'YOUR_OBJECT_KEY',
    'SourceFile' => '/the/path/to/the/file/you/are/uploading.ext',
));
```

If the AWS facade is registered within the `aliases` section of the application configuration, you can also use the following technique.

```
$s3 = AWS::createClient('s3');
$s3->putObject(array(
    'Bucket'     => 'YOUR_BUCKET',
    'Key'        => 'YOUR_OBJECT_KEY',
    'SourceFile' => '/the/path/to/the/file/you/are/uploading.ext',
));
```

To use in Lumen, you need to retrieve it from the service container a bit differently:

```
$s3 = app('aws')->createClient('s3');
$s3->putObject(array(
    'Bucket'     => 'YOUR_BUCKET',
    'Key'        => 'YOUR_OBJECT_KEY',
    'SourceFile' => '/the/path/to/the/file/you/are/uploading.ext',
));
```

Getting Help
------------

[](#getting-help)

Please use these community resources for getting help. We use the GitHub issues for tracking bugs and feature requests and have limited bandwidth to address them.

- Ask a question on [StackOverflow](https://stackoverflow.com/) and tag it with [`aws-php-sdk`](http://stackoverflow.com/questions/tagged/aws-php-sdk)
- Come join the AWS SDK for PHP [gitter](https://gitter.im/aws/aws-sdk-php)
- Open a support ticket with [AWS Support](https://console.aws.amazon.com/support/home/)
- If it turns out that you may have found a bug, please [open an issue](https://github.com/aws/aws-sdk-php-laravel/issues/new/choose)

This SDK implements AWS service APIs. For general issues regarding the AWS services and their limitations, you may also take a look at the [Amazon Web Services Discussion Forums](https://forums.aws.amazon.com/).

### Opening Issues

[](#opening-issues)

If you encounter a bug with `aws-sdk-php-laravel` we would like to hear about it. Search the existing issues and try to make sure your problem doesn’t already exist before opening a new issue. It’s helpful if you include the version of `aws-sdk-php-laravel`, PHP version and OS you’re using. Please include a stack trace and reduced repro case when appropriate, too.

The GitHub issues are intended for bug reports and feature requests. For help and questions with using `aws-sdk-php` please make use of the resources listed in the Getting Help section. There are limited resources available for handling issues and by keeping the list of open issues lean we can respond in a timely manner.

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

[](#contributing)

We work hard to provide a high-quality and useful SDK for our AWS services, and we greatly value feedback and contributions from our community. Please review our [contributing guidelines](./CONTRIBUTING.md) before submitting any issues or pull requests to ensure we have all the necessary information to effectively respond to your bug report or contribution.

Resources
---------

[](#resources)

- [AWS SDK for PHP on Github](http://github.com/aws/aws-sdk-php/)
- [AWS SDK for PHP website](http://aws.amazon.com/sdkforphp/)
- [AWS on Packagist](https://packagist.org/packages/aws/)
- [License](http://aws.amazon.com/apache2.0/)
- [Laravel website](http://laravel.com/)

###  Health Score

78

—

ExcellentBetter than 100% of packages

Maintenance89

Actively maintained with recent releases

Popularity76

Solid adoption and visibility

Community52

Growing community involvement

Maturity84

Battle-tested with a long release history

 Bus Factor3

3 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 ~149 days

Recently: every ~283 days

Total

33

Last Release

55d ago

Major Versions

1.1.2 → 2.0.0-beta.12015-02-19

2.0.1 → 3.0.02015-06-10

1.2.0 → 3.2.02017-11-16

PHP version history (6 changes)1.0.0PHP &gt;=5.3.7

1.0.4PHP &gt;=5.3.3

2.0.0-beta.1PHP &gt;=5.4.0

3.0.0PHP &gt;=5.5.9

3.9.0PHP &gt;=7.2.5

3.10.0PHP &gt;=8.1

### Community

Maintainers

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

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

---

Top Contributors

[![jeremeamia](https://avatars.githubusercontent.com/u/107867?v=4)](https://github.com/jeremeamia "jeremeamia (46 commits)")[![holorhythms](https://avatars.githubusercontent.com/u/38118252?v=4)](https://github.com/holorhythms "holorhythms (20 commits)")[![stobrien89](https://avatars.githubusercontent.com/u/60306702?v=4)](https://github.com/stobrien89 "stobrien89 (16 commits)")[![jeskew](https://avatars.githubusercontent.com/u/705500?v=4)](https://github.com/jeskew "jeskew (10 commits)")[![tomschlick](https://avatars.githubusercontent.com/u/70184?v=4)](https://github.com/tomschlick "tomschlick (5 commits)")[![diehlaws](https://avatars.githubusercontent.com/u/40442261?v=4)](https://github.com/diehlaws "diehlaws (5 commits)")[![mateusjunges](https://avatars.githubusercontent.com/u/19756164?v=4)](https://github.com/mateusjunges "mateusjunges (5 commits)")[![chuck014](https://avatars.githubusercontent.com/u/2904081?v=4)](https://github.com/chuck014 "chuck014 (5 commits)")[![kellertk](https://avatars.githubusercontent.com/u/1083460?v=4)](https://github.com/kellertk "kellertk (3 commits)")[![GrahamCampbell](https://avatars.githubusercontent.com/u/2829600?v=4)](https://github.com/GrahamCampbell "GrahamCampbell (3 commits)")[![SamRemis](https://avatars.githubusercontent.com/u/5881835?v=4)](https://github.com/SamRemis "SamRemis (3 commits)")[![TomasVotruba](https://avatars.githubusercontent.com/u/924196?v=4)](https://github.com/TomasVotruba "TomasVotruba (2 commits)")[![jasonlewis](https://avatars.githubusercontent.com/u/829059?v=4)](https://github.com/jasonlewis "jasonlewis (2 commits)")[![matthewnessworthy](https://avatars.githubusercontent.com/u/5653887?v=4)](https://github.com/matthewnessworthy "matthewnessworthy (2 commits)")[![ajredniwja](https://avatars.githubusercontent.com/u/34409186?v=4)](https://github.com/ajredniwja "ajredniwja (2 commits)")[![cjyclaire](https://avatars.githubusercontent.com/u/10790394?v=4)](https://github.com/cjyclaire "cjyclaire (2 commits)")[![kstich](https://avatars.githubusercontent.com/u/26905335?v=4)](https://github.com/kstich "kstich (2 commits)")[![aykutfarsak](https://avatars.githubusercontent.com/u/311125?v=4)](https://github.com/aykutfarsak "aykutfarsak (2 commits)")[![yenfryherrerafeliz](https://avatars.githubusercontent.com/u/47982775?v=4)](https://github.com/yenfryherrerafeliz "yenfryherrerafeliz (1 commits)")[![digitalfiz](https://avatars.githubusercontent.com/u/157699?v=4)](https://github.com/digitalfiz "digitalfiz (1 commits)")

---

Tags

laravelamazons3sdkawsdynamodbec2laravel 9laravel 10laravel 11laravel 12laravel-13

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/aws-aws-sdk-php-laravel/health.svg)

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

###  Alternatives

[aws/aws-sdk-php-resources

A resource-oriented API for interacting with AWS services

1381.8M10](/packages/aws-aws-sdk-php-resources)[aws/aws-sdk-php-silex

A simple Silex service provider for including the AWS SDK for PHP.

84624.6k2](/packages/aws-aws-sdk-php-silex)[fedemotta/yii2-aws-sdk

This extension provides the AWS SDK integration for the Yii2 framework

15430.4k2](/packages/fedemotta-yii2-aws-sdk)[platinumpixs/aws-symfony2-bundle

A simple Symfony 2 bundle for including the AWS SDK for PHP.

1274.3k1](/packages/platinumpixs-aws-symfony2-bundle)[iwai/aws-sdk-php-phalcon

A simple Phalcon service provider for including the AWS SDK for PHP.

224.3k](/packages/iwai-aws-sdk-php-phalcon)

PHPackages © 2026

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