Laravel 12: Features, Helpers &amp; Upgrade Notes | Mohamed Said        [  ![Mohamed Said](https://cdn.msaied.com/01KT78WE565VEMM3PSNQAAB0MH.png)   Mohamed Said Laravel Backend Engineer  ](https://msaied.com) [ Home ](https://msaied.com) [ Projects ](https://msaied.com/projects) [ Articles  ](https://msaied.com/articles) [ Certificates ](https://msaied.com/certificates) [ Contact ](https://msaied.com#contact-section) 

       [  ](https://github.com/EG-Mohamed)       

 [ Home ](https://msaied.com) [ Projects ](https://msaied.com/projects) [ Articles ](https://msaied.com/articles) [ Certificates ](https://msaied.com/certificates) [ Contact ](https://msaied.com#contact-section) 

  [ home ](https://msaied.com)    [ articles ](https://msaied.com/articles)    Laravel 12: New Features, Helpers, and Practical Upgrade Notes        On this page       1. [  What Actually Changed in Laravel 12 ](#what-actually-changed-in-laravel-12)
2. [  Slimmer Application Skeleton ](#slimmer-application-skeleton)
3. [  First-Party Starter Kits ](#first-party-starter-kits)
4. [  New and Refined Helpers ](#new-and-refined-helpers)
5. [  Upgrade Checklist ](#upgrade-checklist)
6. [  Should You Upgrade Now? ](#should-you-upgrade-now)
7. [  Key Takeaways ](#key-takeaways)

  ![Laravel 12: New Features, Helpers, and Practical Upgrade Notes](https://cdn.msaied.com/276/f03c39eacfb12e24f60198047143483f.png)

  #laravel   #laravel-12   #upgrade   #php  

 Laravel 12: New Features, Helpers, and Practical Upgrade Notes 
================================================================

     23 Jun 2026      4 min read    ![Mohamed Said](https://cdn.msaied.com/01M22N44A70A5MC2S599JP0MPH.webp)  Mohamed Said  

       Table of contents

1. [  01   What Actually Changed in Laravel 12  ](#what-actually-changed-in-laravel-12)
2. [  02   Slimmer Application Skeleton  ](#slimmer-application-skeleton)
3. [  03   First-Party Starter Kits  ](#first-party-starter-kits)
4. [  04   New and Refined Helpers  ](#new-and-refined-helpers)
5. [  05   Upgrade Checklist  ](#upgrade-checklist)
6. [  06   Should You Upgrade Now?  ](#should-you-upgrade-now)
7. [  07   Key Takeaways  ](#key-takeaways)

 What Actually Changed in Laravel 12
-----------------------------------

Laravel 12 is a **minimal-surface release** — the framework team deliberately kept breaking changes small so teams can upgrade without a multi-sprint refactor. That does not mean nothing changed. Several decisions affect how you scaffold new projects and which helpers you reach for day-to-day.

---

### Slimmer Application Skeleton

The default `laravel/laravel` skeleton lost several files that previously shipped but were rarely touched:

- `app/Http/Kernel.php` is gone — middleware is now registered entirely in `bootstrap/app.php` (this started in L11 but L12 finalises the pattern).
- `app/Providers/BroadcastServiceProvider.php` and `app/Providers/EventServiceProvider.php` are no longer generated; their responsibilities live in `AppServiceProvider` or `bootstrap/app.php`.
- The `routes/channels.php` and `routes/console.php` files are opt-in rather than always present.

If you are upgrading an existing L11 app, **none of your existing files are deleted** — the skeleton change only affects `laravel new` projects.

---

### First-Party Starter Kits

Laravel 12 ships three official starter kits via `laravel/breeze` and a new `laravel/react` / `laravel/vue` path:

```bash
# React starter (Inertia v2, TypeScript, Tailwind v4)
laravel new my-app --using=react

# Vue starter
laravel new my-app --using=vue

# Livewire starter (Volt or class-based)
laravel new my-app --using=livewire

```

Each kit now includes **WorkOS AuthKit** as an optional authentication layer, giving you social login and SSO out of the box. You can opt out and keep the classic email/password flow.

> **Practical note:** The `--using` flag delegates to the kit's own installer. If your CI pipeline runs `laravel new`, pin the kit version explicitly to avoid unexpected scaffold changes between patch releases.

---

### New and Refined Helpers

#### `Number::spell()` and `Number::ordinal()`

```php
use Illuminate\Support\Number;

Number::spell(42);       // "forty-two"
Number::ordinal(3);      // "3rd"
Number::ordinal(21);     // "21st"

```

These are thin wrappers around PHP's `NumberFormatter` — no extra dependency, locale-aware via the `locale` argument.

#### `Str::chopStart()` / `Str::chopEnd()`

```php
Str::chopStart('https://example.com', 'https://'); // "example.com"
Str::chopEnd('report.csv', '.csv');                // "report"

```

Clean replacements for the `ltrim`/`rtrim` + manual prefix pattern you have written a hundred times.

#### `once()` helper

```php
function expensiveComputation(): int
{
    return once(fn () => /* runs exactly once per request lifecycle */ 42);
}

```

`once()` memoises the return value of a closure for the duration of the request (or Octane worker tick). It is backed by `Illuminate\Support\Once` and is safe across repeated calls from different call sites.

---

### Upgrade Checklist

For teams moving from Laravel 11:

1. **Run `php artisan about`** on L11 first; note any custom providers.
2. Update `composer.json`: `"laravel/framework": "^12.0"`.
3. Check your `bootstrap/app.php` — if you registered middleware in a custom `Kernel`, migrate it to the fluent API:

```php
// bootstrap/app.php
return Application::configure(basePath: dirname(__DIR__))
    ->withMiddleware(function (Middleware $middleware) {
        $middleware->append(\App\Http\Middleware\TrustProxies::class);
    })
    ->create();

```

4. Search for `Illuminate\Http\Middleware\TrustHosts` — it is now enabled by default; remove duplicate registrations.
5. Run `php artisan config:clear && php artisan cache:clear` before deploying.
6. Review the [official upgrade guide](https://laravel.com/docs/12.x/upgrade) for any package-specific notes (Sanctum, Passport, Telescope all have L12-compatible releases).

---

### Should You Upgrade Now?

If you are on L11 and your app is stable, upgrading is low-risk. The breaking changes are narrow and well-documented. New projects should start on L12 immediately to benefit from the cleaner skeleton and updated starter kits.

---

### Key Takeaways

- The skeleton is leaner — `Kernel.php` is gone, providers are consolidated.
- Three official starter kits (`react`, `vue`, `livewire`) with optional WorkOS auth.
- `Str::chopStart()`, `Str::chopEnd()`, `Number::spell()`, `Number::ordinal()`, and `once()` are worth adopting immediately.
- Upgrading from L11 is straightforward; the main work is migrating any custom `Kernel` middleware to `bootstrap/app.php`.
- Pin starter kit versions in CI to avoid scaffold drift.

 Found this useful?

          [  ](https://twitter.com/intent/tweet?url=https%3A%2F%2Fmsaied.com%2Farticles%2Flaravel-12-new-features-helpers-and-practical-upgrade-notes&text=Laravel+12%3A+New+Features%2C+Helpers%2C+and+Practical+Upgrade+Notes) [  ](https://www.linkedin.com/sharing/share-offsite/?url=https%3A%2F%2Fmsaied.com%2Farticles%2Flaravel-12-new-features-helpers-and-practical-upgrade-notes) 

 Frequently Asked Questions 
----------------------------

  3 questions  

     Q01  Is upgrading from Laravel 11 to Laravel 12 a large effort?        No. Laravel 12 has a small breaking-change surface. Most teams complete the upgrade in a few hours. The main task is migrating any custom HTTP Kernel middleware registrations to the fluent API in bootstrap/app.php. 

      Q02  What is the `once()` helper and when should I use it?        once() memoises a closure's return value for the lifetime of the current request or Octane worker tick. Use it to avoid redundant expensive computations — database lookups, heavy calculations — that are called from multiple places but should only run once per request. 

      Q03  Do the new starter kits replace Laravel Breeze and Jetstream?        The new --using flag kits are the spiritual successor to Breeze for React/Vue/Livewire stacks. Jetstream remains a separate package for teams that need its team management features. Breeze itself is updated to delegate to the new kits. 

  Continue reading

 More Articles 
---------------

 [ View all    ](https://msaied.com/articles) 

 [ ![Live Stream: Building a Social Network in PHP in 48 Hours](https://cdn.msaied.com/692/e20cfd66bbb0473d2084f86b7f5e4dcc.png) PHP Live Stream Nuno Maduro 

### Live Stream: Building a Social Network in PHP in 48 Hours

Nuno Maduro, Brent Roose, and Matthieu Napoli will build a full social network in PHP live from the JetBrains...

  ![Mohamed Said](https://cdn.msaied.com/01M22N44A70A5MC2S599JP0MPH.webp)  Mohamed Said 

 22 Sep 2026     2 min read  

  Read    

 ](https://msaied.com/articles/live-stream-building-a-social-network-in-php-in-48-hours) [ ![Livewire v4.4.6 Released: Bug Fixes, Test Improvements, and Alpine v3.17.4](https://cdn.msaied.com/689/454c52282f3ef5d585905e5952ca969c.png) Livewire Laravel Alpine.js 

### Livewire v4.4.6 Released: Bug Fixes, Test Improvements, and Alpine v3.17.4

Livewire v4.4.6 ships with 18 changes including validation performance improvements, better test assertions, k...

  ![Mohamed Said](https://cdn.msaied.com/01M22N44A70A5MC2S599JP0MPH.webp)  Mohamed Said 

 21 Sep 2026     3 min read  

  Read    

 ](https://msaied.com/articles/livewire-v446-released-bug-fixes-test-improvements-and-alpine-v3174) [ ![Laravel 14: New Features, Breaking Changes, and PHP 8.4 Requirement](https://cdn.msaied.com/688/2dfe8f11b0bef35c0ee6db912004209f.png) Laravel 14 PHP 8.4 Breaking Changes 

### Laravel 14: New Features, Breaking Changes, and PHP 8.4 Requirement

Laravel 14 is expected in Q1 2027 and will require PHP 8.4. Here is everything known so far from the master br...

  ![Mohamed Said](https://cdn.msaied.com/01M22N44A70A5MC2S599JP0MPH.webp)  Mohamed Said 

 21 Sep 2026     4 min read  

  Read    

 ](https://msaied.com/articles/laravel-14-new-features-breaking-changes-and-php-84-requirement) 

   [  ![Mohamed Said](https://cdn.msaied.com/01KT78WE565VEMM3PSNQAAB0MH.png)   Mohamed Said Laravel Backend Engineer  ](https://msaied.com)Senior Backend Engineer specializing in Laravel, scalable SaaS platforms, APIs, and cloud infrastructure. I build secure, high-performance web applications that help businesses grow.

Explore

- [Home](https://msaied.com)
- [Projects](https://msaied.com/projects)
- [Articles](https://msaied.com/articles)
- [Certificates](https://msaied.com/certificates)
- [Contact](https://msaied.com#contact-section)

Connect

- [   hello@msaied.com ](mailto:hello@msaied.com)
- [   +20 109 461 9204 ](tel:+201094619204)

© 2026 Mohamed Said. All rights reserved.

 [  ](https://github.com/EG-Mohamed) [  ](https://www.linkedin.com/in/msaiedm/) [  ](https://wa.me/201094619204) [  ](mailto:hello@msaied.com) [  ](https://drive.google.com/file/u/0/d/1MF20IPRJyzfy32mhEutjL5EpSls0w2Q8/view)
