{
  "id": 11836237,
  "title": "Laravel Route Model Binding: Implicit, Explicit & Scoped",
  "url": "https://urgent.news/2026/10/04/laravel-route-model-binding-implicit-explicit-scoped",
  "topic": "tech",
  "section": "Tech",
  "published": "2026-10-04T03:45:32.000Z",
  "source": {
    "name": "Dev.to",
    "slug": "dev-to",
    "url": "https://dev.to/devtalk94/laravel-route-model-binding-implicit-explicit-scoped-4igf"
  },
  "original_language": "en",
  "account": "Laravel route model binding automates the process of retrieving Eloquent models based on URL parameters, eliminating the need for manual lookups. Implicit binding matches the route parameter name to the type-hinted model variable, resolving the model automatically. For custom lookup columns or soft-deleted rows, binding can be scoped to specific columns or enabled with the withTrashed() method. Scoped bindings allow nested resources to properly associate related records, preventing unauthorized access to other users' data. Explicit binding provides a centralized solution for custom resolution logic applicable across multiple routes. Soft-deleted models are excluded by default but can be included using the withTrashed() method, though care must be taken to ensure compatibility when combining scoped and trashed bindings on parent/child model pairs.",
  "summary": "Laravel route model binding is the reason a resource controller rarely contains a manual Post::findOrFail($id) call. Part 1 covered how Laravel routing works at a basic level, and ended on the {post} parameter in a resource route resolving straight to a Post model instead of a raw ID. This part covers how that actually happens, and the handful of places it stops working the way you'd expect:…",
  "key_points": [
    "Laravel route model binding automates Eloquent model retrieval from URL parameters",
    "Implicit binding matches route parameter names to type-hinted model variables",
    "Scoped bindings enable custom column lookups and soft-deleted row inclusion"
  ],
  "editors_take": "This development streamlines Laravel's model retrieval process, allowing for more efficient and secure handling of related records and soft-deleted data through various binding methods.",
  "illustration": null,
  "coverage": {
    "outlets": 1,
    "also_reported_by": []
  },
  "ai_generated": true,
  "disclaimer": "Summaries, key points and the editor’s take are written by software from other outlets’ reporting and may contain errors — always check the linked original."
}