spatie/eloquent-sortable
Sortable behaviour for eloquent models
5.0.1
28M downloads/mo
#656 most downloaded on Packagist
spatie/eloquent-sortable
What this package is like to depend on
Last release 6 months ago
21 Feb 2026
Release timing varies
gaps range from 9 days to 11 months
Most releases are documented
notes for 44 of 54 stable releases
Nothing withdrawn
no release was ever pulled
12 years old
54 releases · first in 2014
2 releases in the last 12 months
see the full history below
Release timeline
54 releases · Jul 2014 to Feb 2026Releases
latest 54-
5.0.121 Feb 2026 -
5.0.012 Feb 2026Release notes
Open source →What's changed
- Use
save()instead ofsaveQuietly()inmoveAfterandmoveBeforefor consistent model event behavior (#200) - Drop support for PHP 8.1 (EOL)
- Drop support for Laravel 9 (EOL)
Breaking changes
- Minimum PHP version is now 8.2
- Minimum Laravel version is now 10
moveAfterandmoveBeforenow fire model events (previously usedsaveQuietly())
Release notes
Open source →What's changed
- Use
save()instead ofsaveQuietly()inmoveAfterandmoveBeforefor consistent model event behavior (#200) - Drop support for PHP 8.1 (EOL)
- Drop support for Laravel 9 (EOL)
Breaking changes
- Minimum PHP version is now 8.2
- Minimum Laravel version is now 10
moveAfterandmoveBeforenow fire model events (previously usedsaveQuietly())
- Use
-
4.5.225 Aug 2025Release notes
Open source →What's Changed
- Revert "Check for parent::buildSortQuery() (#188)" by @phh in https://github.com/spatie/eloquent-sortable/pull/193
New Contributors
- @phh made their first contribution in https://github.com/spatie/eloquent-sortable/pull/193
Full Changelog: https://github.com/spatie/eloquent-sortable/compare/4.5.1...4.5.2
-
4.5.125 Aug 2025Release notes
Open source →What's Changed
- Check for parent::buildSortQuery() by @JeroenHauser in #188
- Bump actions/checkout from 4 to 5 by @dependabot[bot] in #191
- Bump stefanzweifel/git-auto-commit-action from 5 to 6 by @dependabot[bot] in #190
New Contributors
- @JeroenHauser made their first contribution in #188
Full Changelog: 4.5.0...4.5.1
Release notes
Open source →What's Changed
- Check for parent::buildSortQuery() by @JeroenHauser in https://github.com/spatie/eloquent-sortable/pull/188
- Bump actions/checkout from 4 to 5 by @dependabot[bot] in https://github.com/spatie/eloquent-sortable/pull/191
- Bump stefanzweifel/git-auto-commit-action from 5 to 6 by @dependabot[bot] in https://github.com/spatie/eloquent-sortable/pull/190
New Contributors
- @JeroenHauser made their first contribution in https://github.com/spatie/eloquent-sortable/pull/188
Full Changelog: https://github.com/spatie/eloquent-sortable/compare/4.5.0...4.5.1
-
4.5.003 Jun 2025Release notes
Open source →What's Changed
- Bump dependabot/fetch-metadata from 2.3.0 to 2.4.0 by @dependabot in #187
- Add
moveAfterandmoveBeforemethods for precise positioning by @SebastiaanKloos in #189
New Contributors
- @SebastiaanKloos made their first contribution in #189
Full Changelog: 4.4.2...4.5.0
Release notes
Open source →What's Changed
- Bump dependabot/fetch-metadata from 2.3.0 to 2.4.0 by @dependabot in https://github.com/spatie/eloquent-sortable/pull/187
- Add
moveAfterandmoveBeforemethods for precise positioning by @SebastiaanKloos in https://github.com/spatie/eloquent-sortable/pull/189
New Contributors
- @SebastiaanKloos made their first contribution in https://github.com/spatie/eloquent-sortable/pull/189
Full Changelog: https://github.com/spatie/eloquent-sortable/compare/4.4.2...4.5.0
-
4.4.219 Feb 2025Release notes
Open source →What's Changed
- Bump dependabot/fetch-metadata from 2.2.0 to 2.3.0 by @dependabot in #185
- Laravel 12.x Compatibility by @laravel-shift in #186
New Contributors
- @laravel-shift made their first contribution in #186
Full Changelog: 4.4.1...4.4.2
Release notes
Open source →What's Changed
- Bump dependabot/fetch-metadata from 2.2.0 to 2.3.0 by @dependabot in https://github.com/spatie/eloquent-sortable/pull/185
- Laravel 12.x Compatibility by @laravel-shift in https://github.com/spatie/eloquent-sortable/pull/186
New Contributors
- @laravel-shift made their first contribution in https://github.com/spatie/eloquent-sortable/pull/186
Full Changelog: https://github.com/spatie/eloquent-sortable/compare/4.4.1...4.4.2
-
4.4.123 Dec 2024Release notes
Open source →What's Changed
- Bump dependabot/fetch-metadata from 1.6.0 to 2.1.0 by @dependabot in #176
- Bump dependabot/fetch-metadata from 2.1.0 to 2.2.0 by @dependabot in #181
- Fix PHP 8.4 deprecation notice by @clarkewing in #184
New Contributors
- @clarkewing made their first contribution in #184
Full Changelog: 4.4.0...4.4.1
Release notes
Open source →What's Changed
- Bump dependabot/fetch-metadata from 1.6.0 to 2.1.0 by @dependabot in https://github.com/spatie/eloquent-sortable/pull/176
- Bump dependabot/fetch-metadata from 2.1.0 to 2.2.0 by @dependabot in https://github.com/spatie/eloquent-sortable/pull/181
- Fix PHP 8.4 deprecation notice by @clarkewing in https://github.com/spatie/eloquent-sortable/pull/184
New Contributors
- @clarkewing made their first contribution in https://github.com/spatie/eloquent-sortable/pull/184
Full Changelog: https://github.com/spatie/eloquent-sortable/compare/4.4.0...4.4.1
-
4.4.004 Jun 2024Release notes
Open source →What's Changed
- Dispatch event after performing a sort by @chrispage1 in #178
New Contributors
- @chrispage1 made their first contribution in #178
Full Changelog: 4.3.0...4.4.0
Release notes
Open source →What's Changed
- Dispatch event after performing a sort by @chrispage1 in https://github.com/spatie/eloquent-sortable/pull/178
New Contributors
- @chrispage1 made their first contribution in https://github.com/spatie/eloquent-sortable/pull/178
Full Changelog: https://github.com/spatie/eloquent-sortable/compare/4.3.0...4.4.0
-
4.3.002 May 2024Release notes
Open source →What's Changed
- Use model's qualified key name for update queries by @JeremyDunn in #175
New Contributors
- @JeremyDunn made their first contribution in #175
Full Changelog: 4.2.0...4.3.0
Release notes
Open source →What's Changed
- Use model's qualified key name for update queries by @JeremyDunn in https://github.com/spatie/eloquent-sortable/pull/175
New Contributors
- @JeremyDunn made their first contribution in https://github.com/spatie/eloquent-sortable/pull/175
Full Changelog: https://github.com/spatie/eloquent-sortable/compare/4.2.0...4.3.0
-
4.2.026 Feb 2024Release notes
Open source →What's Changed
- Bump stefanzweifel/git-auto-commit-action from 4 to 5 by @dependabot in #162
- Support laravel 11 by @mokhosh in #171
- bump min laravel 9 version to support ignore timestamps by @mokhosh in #173
Full Changelog: 4.1.1...4.2.0
Release notes
Open source →What's Changed
- Bump stefanzweifel/git-auto-commit-action from 4 to 5 by @dependabot in https://github.com/spatie/eloquent-sortable/pull/162
- Support laravel 11 by @mokhosh in https://github.com/spatie/eloquent-sortable/pull/171
- bump min laravel 9 version to support ignore timestamps by @mokhosh in https://github.com/spatie/eloquent-sortable/pull/173
Full Changelog: https://github.com/spatie/eloquent-sortable/compare/4.1.1...4.2.0
-
4.1.122 Jan 2024Release notes
Open source →What's Changed
- Fix typo in eloquent-sortable.php by @dissto in https://github.com/spatie/eloquent-sortable/pull/168
- Add ignore timestamp by @mokhosh in https://github.com/spatie/eloquent-sortable/pull/169
New Contributors
- @dissto made their first contribution in https://github.com/spatie/eloquent-sortable/pull/168
- @mokhosh made their first contribution in https://github.com/spatie/eloquent-sortable/pull/169
Full Changelog: https://github.com/spatie/eloquent-sortable/compare/4.1.0...4.1.1
-
4.1.011 Dec 2023Release notes
Open source →- add support for Laravel 10
- drop support for Laravel 8
- drop support for PHP 8.0
-
4.0.223 Jan 2023Release notes
Open source →What's Changed
- Update readme about publishing config file by @patrickbrouwers in https://github.com/spatie/eloquent-sortable/pull/120
- Add Dependabot Automation by @patinthehat in https://github.com/spatie/eloquent-sortable/pull/136
- Bump actions/checkout from 2 to 3 by @dependabot in https://github.com/spatie/eloquent-sortable/pull/137
- Add PHP 8.2 Support by @patinthehat in https://github.com/spatie/eloquent-sortable/pull/138
- Laravel 10 support by @Okipa in https://github.com/spatie/eloquent-sortable/pull/142
New Contributors
- @patrickbrouwers made their first contribution in https://github.com/spatie/eloquent-sortable/pull/120
- @dependabot made their first contribution in https://github.com/spatie/eloquent-sortable/pull/137
- @Okipa made their first contribution in https://github.com/spatie/eloquent-sortable/pull/142
Full Changelog: https://github.com/spatie/eloquent-sortable/compare/4.0.1...4.0.2
-
4.0.121 Jan 2022 -
4.0.031 Mar 2021 -
3.11.018 Jan 2021Release notes
Open source →- add methods to determine whether element is the last or first in order (#102)
-
3.10.025 Nov 2020 -
3.9.015 Sep 2020 -
3.8.308 Sep 2020 -
3.8.208 Jul 2020 -
3.8.126 Jun 2020 -
3.8.002 Mar 2020 -
3.7.004 Sep 2019 -
3.6.001 Apr 2019 -
3.5.027 Feb 2019 -
3.4.427 Feb 2019 -
3.4.324 Aug 2018 -
3.4.207 Feb 2018 -
3.4.131 Aug 2017 -
3.4.030 Aug 2017 -
3.3.016 Apr 2017 -
3.2.123 Jan 2017 -
3.2.023 Jan 2017 -
3.1.020 Nov 2016 -
3.0.021 Oct 2016 -
2.3.019 Oct 2016 -
2.2.019 Oct 2016 -
2.1.121 Mar 2016 -
2.1.025 Feb 2016 -
2.0.110 Aug 2015 -
2.0.006 Aug 2015Release notes
Open source →- SortableInterface is now Sortable
- Sortable is now SortableTrait
- getHighestOrderNumber() now retrieves the highest existing order number (not a new one)
- setHighestOrderNumber() no longer requires a Sortable object parameter
- sort_when_creating option
- Added shouldSortWhenCreating function
- Added test coverage
-
1.1.211 Jun 2015 -
1.1.111 Jun 2015 -
1.1.011 Jun 2015Release notes
Open source →- Added an argument to
setNewOrderto specify the starting order - Adopted psr-2 and psr-4
- Added an argument to
-
1.0.222 May 2015Nothing published for this version
-
1.0.118 May 2015Nothing published for this version
-
1.0.013 Feb 2015Nothing published for this version
-
0.2.226 Jan 2015Nothing published for this version
-
0.2.114 Oct 2014Nothing published for this version
-
0.1.402 Sep 2014Nothing published for this version
-
0.1.315 Jul 2014Nothing published for this version
-
0.1.215 Jul 2014Nothing published for this version
-
0.1.115 Jul 2014Nothing published for this version
-
0.1.015 Jul 2014Nothing published for this version