Major release

Laravel 13: what's new and how to upgrade from Laravel 12

Major release

Laravel 13.0.0 was released on 17 Mar 2026, the framework's yearly major version. Eight months on, the 13.x line has had more than forty minor releases (13.43.0 came out on 17 Nov 2026), and Laravel 12 has already stopped receiving bug fixes. If you run a business system on Laravel 12 or older, this page explains what Laravel 13 brings, which changes can actually break something, and how to plan the move.

The short version

  • PHP 8.3 is the new minimum. The official support table lists PHP 8.3 to 8.5 for Laravel 13.
  • Few breaking changes by design. The Laravel team says most applications can upgrade without changing much code, and the official guide estimates about 10 minutes for a typical app. Large systems with custom packages need more than that.
  • Security defaults are stricter. The CSRF middleware is renamed and now also checks where a request came from. New apps also get safer cache and session serialisation settings.
  • Support runs to March 2028. Bug fixes continue until Q3 2027 and security fixes until 17 Mar 2028.

Where each Laravel version stands today

Laravel's policy gives every major version 18 months of bug fixes and two years of security fixes. Applied to today's date:

VersionPHPReleasedBug fixes untilSecurity fixes untilStatus on 26 Nov 2026
Laravel 138.3 to 8.517 Mar 2026Q3 202717 Mar 2028Fully supported
Laravel 128.2 to 8.524 Feb 202513 Aug 202624 Feb 2027Security fixes only
Laravel 118.2 to 8.412 Mar 20243 Sep 202512 Mar 2026End of life
Laravel 10 and olderEnd of life

Laravel 12 still gets security releases (12.74.0 was published on 24 Nov 2026), but only until 24 Feb 2027. That leaves about three months to plan the upgrade calmly instead of in a rush. Systems still on Laravel 11 or older are already outside any official fix.

PHP 8.6 was released on 19 Nov 2026, and the Laravel support table currently lists PHP up to 8.5 for version 13. Check the official table and your packages before moving a Laravel server to 8.6. Our PHP 8.6 page covers what changed in the language.

What is new in Laravel 13

The release notes group the new features around a few themes. These are the ones most relevant to business systems:

  • Origin-aware request forgery protection. The CSRF middleware is now called PreventRequestForgery. On top of the usual token check, it uses the browser's Sec-Fetch-Site header to verify where a request originated.
  • Queue routing by class. Queue::route() lets you set the default connection and queue for a job class in one central place, instead of repeating it wherever the job is dispatched.
  • More PHP attributes. Controllers can declare middleware and authorisation with #[Middleware] and #[Authorize], and jobs can declare #[Tries], #[Backoff] and #[Timeout] on the class itself.
  • JSON:API resources. First-party support for API responses that follow the JSON:API specification, including relationships, sparse fieldsets and the right headers. Useful when a mobile app or a partner consumes your API.
  • Cache::touch(). Extends the lifetime of a cached item without reading and rewriting its value.
  • AI and vector search. A first-party AI SDK and vector similarity queries for PostgreSQL with pgvector. These are optional and matter only if you plan features like semantic search over your own documents.
// Route a job class to a queue in one place (e.g. a service provider)
Queue::route(ProcessInvoice::class, connection: 'redis', queue: 'invoices');

The changes that can break an upgrade

The upgrade guide rates each change by how likely it is to affect you. Here is our reading of the ones that matter in real projects:

High impact

  1. Dependencies. In composer.json, move laravel/framework to ^13.0, laravel/tinker to ^3.0, and your test runner to phpunit/phpunit ^12.0 or pestphp/pest ^4.0. Third-party packages must also support 13; this is usually the slowest step.
  2. CSRF middleware rename. VerifyCsrfToken and ValidateCsrfToken still work as deprecated aliases, but any direct reference, for example when excluding the middleware in tests or routes, should switch to PreventRequestForgery. Test any flow where another site posts back to yours, such as a payment gateway callback.

Medium impact

  • Cache unserialisation. The default cache config now has serializable_classes set to false, which blocks PHP objects from being restored from the cache. If your app caches objects, list the allowed classes explicitly or cache arrays instead.
  • upsert() needs uniqueBy. An empty uniqueBy now throws an exception on MySQL and MariaDB instead of quietly producing a query.

Low impact, but worth a search

  • Session serialisation. The new skeleton uses json for sessions. If you copy the new config/session.php into an existing app, every signed-in user is logged out. Keep php if that would be a problem.
  • Cache prefix and session cookie names. If your app relies on framework defaults instead of setting CACHE_PREFIX, REDIS_PREFIX and SESSION_COOKIE, the generated names change, which empties the cache and ends sessions. Set them explicitly before upgrading.
  • Global scopes in nested where closures. Removing a global scope inside a nested closure now removes it from the whole query, so some queries may return records they used to exclude. Search for withoutGlobalScope and onlyTrashed inside closures.
  • Joined DELETE with ORDER BY or LIMIT on MySQL may now throw an error instead of running without the limit.
  • array_first() and array_last(). A new PHP 8.5 polyfill defines these global functions, which can clash with old helper packages. Prefer Arr::first() and Arr::last().

A safe upgrade path for a live system

  1. Confirm the server runs PHP 8.3 or newer, and on the latest security release of its branch. Our PHP security releases page lists the safe version per branch.
  2. Update the app to the latest Laravel 12 release first, and clear its deprecation warnings.
  3. Run composer outdated and check that every package you depend on has a release supporting Laravel 13.
  4. On a separate branch and a staging copy, change the versions, run composer update, and work through the guide's list above.
  5. Run the automated tests, then test by hand: sign-in, payments and their callbacks, file uploads, queued jobs, scheduled tasks and reports.
  6. Deploy at a quiet time with a tested rollback, and watch the error log for the first days.

Upgrading systems like these is regular work in our custom software service. If your system is on Laravel 11 or older and you're not sure how big the jump is, tell us about it and we'll assess it.

FAQ

Do I have to upgrade from Laravel 12 right now?

Not this week, but soon. Laravel 12 stopped getting bug fixes on 13 Aug 2026 and gets security fixes only until 24 Feb 2027. Plan the upgrade now so it happens before that date, not after it.

Will Laravel 13 run on my current hosting?

Only if the server runs PHP 8.3 or newer. Many shared hosts still default to older versions, so check the version used by the website (in cPanel, MultiPHP Manager), not just the command-line version.

Can I skip from Laravel 10 or 11 straight to 13?

The official guides are written one version at a time, so in practice you apply the changes for 11, then 12, then 13. It can be done in one project, but each step's list must be followed and tested.

Is the "10 minutes" upgrade estimate realistic?

For a small, standard app with few packages, often yes. For a business system with many packages, custom code and integrations, most of the time goes into checking packages and testing, not into the framework changes themselves.

Do I need to use the AI features to upgrade?

No. The AI SDK and vector search are optional additions. An application that doesn't use them upgrades the same way and isn't affected by them.

Official sources

Visual Innovate

Written by the Visual Innovate team, the people who build, host and follow up systems, websites and apps for our clients in Jordan, Saudi Arabia, Oman and Egypt. We follow the official sources and update this page when something changes.

Are you our next Success Partner?

Tell us the problem as you see it. Within one working day we'll come back with how we understand it and a clear first step.