PHPackages                             spatie/laravel-cronless-schedule - 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. spatie/laravel-cronless-schedule

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

spatie/laravel-cronless-schedule
================================

Run the Laravel scheduler without relying on cron

1.3.0(4mo ago)391329.6k↓31.9%141MITPHPPHP ^7.4|^8.0CI passing

Since Jun 10Pushed 4mo ago8 watchersCompare

[ Source](https://github.com/spatie/laravel-cronless-schedule)[ Packagist](https://packagist.org/packages/spatie/laravel-cronless-schedule)[ Docs](https://github.com/spatie/laravel-cronless-schedule)[ Fund](https://spatie.be/open-source/support-us)[ GitHub Sponsors](https://github.com/spatie)[ RSS](/packages/spatie-laravel-cronless-schedule/feed)WikiDiscussions main Synced 3d ago

READMEChangelog (9)Dependencies (5)Versions (11)Used By (1)

Run the Laravel scheduler without relying on cron
=================================================

[](#run-the-laravel-scheduler-without-relying-on-cron)

[![Latest Version on Packagist](https://camo.githubusercontent.com/1774cff17dacae3064d7628526bead90583cf9050925b1aee18a544dcff5bc54/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f7370617469652f6c61726176656c2d63726f6e6c6573732d7363686564756c652e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/spatie/laravel-cronless-schedule)[![Tests](https://github.com/spatie/laravel-cronless-schedule/workflows/Tests/badge.svg)](https://github.com/spatie/laravel-cronless-schedule/workflows/Tests/badge.svg)[![Total Downloads](https://camo.githubusercontent.com/160794f223b62b57a0cb49596fed5556bdb1142555b98d7fba48b9a80e243efc/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f7370617469652f6c61726176656c2d63726f6e6c6573732d7363686564756c652e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/spatie/laravel-cronless-schedule)

[Laravel's native scheduler](https://laravel.com/docs/master/scheduling) relies on cron to be executed every minute. It's rock solid and in most cases you should stick to using it.

If you want to simulate the scheduler running every minute in a test environment, using cron can be cumbersome. This package provides a command to run the scheduler every minute, without relying on cron. Instead it uses a [ReactPHP](https://reactphp.org) loop.

This is how you can start the cronless schedule:

```
php artisan schedule:run-cronless
```

This command will never end. Behind the scenes it will execute `php artisan schedule` every minute.

Support us
----------

[](#support-us)

[![](https://camo.githubusercontent.com/bde8d0d96211f6325c34eb7254dc350f65d99020fa808002b8cad00347eba840/68747470733a2f2f6769746875622d6164732e73332e65752d63656e7472616c2d312e616d617a6f6e6177732e636f6d2f6c61726176656c2d63726f6e6c6573732d7363686564756c652e6a70673f743d31)](https://spatie.be/github-ad-click/laravel-cronless-schedule)

We invest a lot of resources into creating [best in class open source packages](https://spatie.be/open-source). You can support us by [buying one of our paid products](https://spatie.be/open-source/support-us).

We highly appreciate you sending us a postcard from your hometown, mentioning which of our package(s) you are using. You'll find our address on [our contact page](https://spatie.be/about-us). We publish all received postcards on [our virtual postcard wall](https://spatie.be/open-source/postcards).

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

[](#installation)

You can install the package via composer. Probably you only want to use this schedule in a development environment.

```
composer require spatie/laravel-cronless-schedule --dev
```

Usage
-----

[](#usage)

This is how you can start the cronless schedule:

```
php artisan schedule:run-cronless
```

By default, it will run every minute.

### Manually triggering a run

[](#manually-triggering-a-run)

To perform an extra run of the scheduler, just press enter.

### Using an alternative frequency

[](#using-an-alternative-frequency)

If you want to run the scheduler at another frequency, you can pass an amount of seconds to the `frequency` option. Here is an example where the schedule will be run every 5 seconds.

```
php artisan schedule:run-cronless --frequency=5
```

### Using another command

[](#using-another-command)

If you want to run another command instead of the scheduler, just can pass it to the `command` option. Here is an example where another command will be run every 5 seconds.

```
php artisan schedule:run-cronless --command=your-favorite-artisan-command
```

### Only run the schedule for a certain period

[](#only-run-the-schedule-for-a-certain-period)

By default, the command will run forever. You can shorten that period by passing an amount of seconds to the `stop-after-seconds` option.

In this example we'll stop the command after 5 seconds

```
php artisan schedule:run-cronless --stop-after-seconds=5
```

Testing
-------

[](#testing)

```
composer test
```

Changelog
---------

[](#changelog)

Please see [CHANGELOG](CHANGELOG.md) for more information on what has changed recently.

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

[](#contributing)

Please see [CONTRIBUTING](https://github.com/spatie/.github/blob/main/CONTRIBUTING.md) for details.

Security
--------

[](#security)

If you've found a bug regarding security please mail  instead of using the issue tracker.

Credits
-------

[](#credits)

- [Freek Van der Herten](https://github.com/freekmurze)
- [All Contributors](../../contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

59

—

FairBetter than 98% of packages

Maintenance76

Regular maintenance activity

Popularity54

Moderate usage in the ecosystem

Community23

Small or concentrated contributor base

Maturity67

Established project with proven stability

 Bus Factor1

Top contributor holds 71.1% 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 ~231 days

Recently: every ~374 days

Total

10

Last Release

130d ago

Major Versions

0.9.0 → 1.0.02020-06-10

PHP version history (2 changes)0.0.1PHP ^7.4

1.0.2PHP ^7.4|^8.0

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/7535935?v=4)[Spatie](/maintainers/spatie)[@spatie](https://github.com/spatie)

---

Top Contributors

[![freekmurze](https://avatars.githubusercontent.com/u/483853?v=4)](https://github.com/freekmurze "freekmurze (54 commits)")[![laravel-shift](https://avatars.githubusercontent.com/u/15991828?v=4)](https://github.com/laravel-shift "laravel-shift (8 commits)")[![AdrianMrn](https://avatars.githubusercontent.com/u/12762044?v=4)](https://github.com/AdrianMrn "AdrianMrn (6 commits)")[![alexmanase](https://avatars.githubusercontent.com/u/10696975?v=4)](https://github.com/alexmanase "alexmanase (3 commits)")[![AlexVanderbist](https://avatars.githubusercontent.com/u/6287961?v=4)](https://github.com/AlexVanderbist "AlexVanderbist (2 commits)")[![devfaysal](https://avatars.githubusercontent.com/u/16212149?v=4)](https://github.com/devfaysal "devfaysal (1 commits)")[![mahmutbayri](https://avatars.githubusercontent.com/u/1398166?v=4)](https://github.com/mahmutbayri "mahmutbayri (1 commits)")[![tominon](https://avatars.githubusercontent.com/u/508519?v=4)](https://github.com/tominon "tominon (1 commits)")

---

Tags

artisancronlaravelphpschedulerspatielaravel-cronless-schedule

###  Code Quality

TestsPest

### Embed Badge

![Health badge](/badges/spatie-laravel-cronless-schedule/health.svg)

```
[![Health](https://phpackages.com/badges/spatie-laravel-cronless-schedule/health.svg)](https://phpackages.com/packages/spatie-laravel-cronless-schedule)
```

###  Alternatives

[psalm/plugin-laravel

Psalm plugin for Laravel

3355.3M346](/packages/psalm-plugin-laravel)[spatie/laravel-multitenancy

Make your Laravel app usable by multiple tenants

1.4k3.4M20](/packages/spatie-laravel-multitenancy)[spatie/laravel-export

Create a static site bundle from a Laravel app

674146.0k6](/packages/spatie-laravel-export)[illuminate/pagination

The Illuminate Pagination package.

12234.1M1.0k](/packages/illuminate-pagination)[illuminate/pipeline

The Illuminate Pipeline package.

9349.2M282](/packages/illuminate-pipeline)

PHPackages © 2026

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