{"id":7459,"date":"2022-02-10T18:12:43","date_gmt":"2022-02-10T18:12:43","guid":{"rendered":"https:\/\/www.hostingseekers.com\/blog\/?p=7459"},"modified":"2025-03-06T11:35:28","modified_gmt":"2025-03-06T11:35:28","slug":"laravel-9-released-what-should-you-expect","status":"publish","type":"post","link":"https:\/\/www.hostingseekers.com\/blog\/laravel-9-released-what-should-you-expect\/","title":{"rendered":"Laravel 9 Released: What Should You Expect?"},"content":{"rendered":"<blockquote><p><span style=\"font-weight: 400;\">The newly released Laravel 9 is highly scalable and comes with so many new features, including a minimum PHP v8.0 version, controller route groups, a refreshed default Ignition error page, Laravel Scout database engine, Symfony mailer integration, Flysystem 3.x, Improved Eloquent accessors\/mutators, and various other features.\u00a0<\/span><\/p><\/blockquote>\n<p><span style=\"font-weight: 400;\">Earlier, Laravel updates were released every 6<\/span><span style=\"font-weight: 400;\">th<\/span><span style=\"font-weight: 400;\"> month. However, with the latest release of Laravel 9 in February 2022, the company has moved its framework to a 12-month major release cycle.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">New Laravel 9 is the next long-term support version (LTS) and will receive bug fixes until February 2024 and security fixes until February 2025.\u00a0<\/span><\/p>\n<hr \/>\n<h2><b>What is Laravel?<\/b><\/h2>\n<p><span style=\"font-weight: 400;\">Laravel is an open-source PHP web application framework that is known for its elegant syntax. It includes an MVC framework that can be used to build simple to complex web applications using PHP programming language. It strictly adheres to the MVC (model-view-controller) architectural pattern.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">Laravel also uses various community-driven packages as well as Symfony components to utilize several features within the framework.\u00a0<\/span><\/p>\n<hr \/>\n<h2><b>New Features of Laravel 9\u00a0<\/b><\/h2>\n<p><span style=\"font-weight: 400;\">The new features and improvements that you can expect in the newly released Laravel 9 are \u2013<\/span><\/p>\n<h3><b>Minimum PHP Requirement\u00a0<\/b><\/h3>\n<p><span style=\"font-weight: 400;\">First things first, Laravel requires the latest PHP 8 and PHPUnit 8 for testing. This is because Laravel 9 has the newest Symfony 6.0, which also operates on PHP 8.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">PHP 8 has new features from the JIT compile to constructor property promotion.<\/span><\/p>\n<h3><b>Anonymous Stub Migration\u00a0<\/b><\/h3>\n<p><span style=\"font-weight: 400;\">When you run the popular migration command (given below), Laravel will make anonymous stub migration behavior.<\/span><\/p>\n<p><i><span style=\"font-weight: 400;\">php artisan make:migration<\/span><\/i><\/p>\n<p><span style=\"font-weight: 400;\">As the anonymous stub migration feature was released in Laravel 8.37 to fix the Github issues, the new Laravel 9 framework that too supports anonymous class migration files, will now set it up to default behavior.<\/span><\/p>\n<h3><b>New Query Builder Interface\u00a0<\/b><\/h3>\n<p><span style=\"font-weight: 400;\">The new Laravel 9 provides type hinting a highly reliable for refactoring, static analysis, and code completion in their IDEs.\u00a0<\/span><\/p>\n<hr \/>\n<h2><b>PHP 8 String Functions\u00a0<\/b><\/h2>\n<p>New Design for routes:list<\/p>\n<p>New test \u2018\u2014coverage\u2019 options display coverage directly in the terminal<\/p>\n<p>Mailer function moved from SwiftMailer to Symfony Mailer.<\/p>\n<p>Improvised Eloquent Accessors\/Mutators<\/p>\n<p>Flysystem 3.x<\/p>\n<p>Implicit Route building with Enums (PHP 8.1)<\/p>\n<p>Controller Route Groups<\/p>\n<p>Enum Eloquent Attribute Casting<\/p>\n<p>Forced Scoped Bindings<\/p>\n<p>Laravel Breeze API &amp; Next.js<\/p>\n<p>Laravel Scout Database Engine<\/p>\n<p>Full-Text Indexes and Where Clauses<\/p>\n<p>Inline Blade Templates rendering<\/p>\n<p>Soketi Echo Server<\/p>\n<p>Optional Bootstrap 5 Pagination View<\/p>\n<p>Improvised Ignition Exception Page<\/p>\n<p>New \u2018str()\u2019 and \u2018to_route()\u2019 helper functions.<\/p>\n<hr \/>\n<h2><b>How To Install Laravel 9?<\/b><\/h2>\n<p><span style=\"font-weight: 400;\">If you want to use the new Laravel 9 for development and testing purposes, then you can easily do it now on your machine.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">Laravel 9 also supports PHP version 8, so make sure to check your PHP version or do a fresh installation.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">Using composer, you can install Laravel 9. Simply run the following command:<\/span><\/p>\n<p><i><span style=\"font-weight: 400;\">composer create-project &#8211;prefer-dist laravel\/laravel laravel-9-dev dev-develop<\/span><\/i><\/p>\n<p><span style=\"font-weight: 400;\">The above command will create a new Laravel project with the name Laravel-9-dev that uses the latest Laravel 9.<\/span><\/p>\n<hr \/>\n<h2><b>How To Upgrade Laravel From 8.x to 9?<\/b><\/h2>\n<p><span style=\"font-weight: 400;\">The up-gradation process may take nearly around 30 minutes.<\/span><span style=\"font-weight: 400;\"><br \/>\n<\/span><\/p>\n<p><span style=\"font-weight: 400;\">To Update Dependencies \u2013<\/span><\/p>\n<p><span style=\"font-weight: 400;\">Laravel<\/span><span style=\"font-weight: 400;\"> now needs to have PHP 8.0.2 or greater.<\/span><\/p>\n<h3><b>Composer Dependencies<\/b><b><br \/>\n<\/b><\/h3>\n<p><span style=\"font-weight: 400;\">Firstly, you will have to update the following dependencies in your application\u2019s composer.json file:<\/span><span style=\"font-weight: 400;\"><br \/>\n<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">laravel\/framework to ^9.0<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">nunomaduro\/collision to ^6.1<\/span><span style=\"font-weight: 400;\"><br \/>\n<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400;\">Once, it is done. Now, replace facade\/ignition with &#8220;spatie\/laravel-ignition&#8221;: &#8220;^1.0\u00a0<\/span><\/p>\n<p><span style=\"font-weight: 400;\">In the same composer.json file.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">Now, see if you are using any third-party packages and verify from the support that now you have Laravel 9 updated.<\/span><\/p>\n<h3><b>#PHP Return Types<\/b><b><br \/>\n<\/b><\/h3>\n<p><span style=\"font-weight: 400;\">Laravel 9 has implemented offsetGet, offsetSet, etc. return types in its codebase. These should actually not affect the user-written code, however in case you are overriding one of these methods by extending Laravel&#8217;s core classes, then you will have to add the following return types, to your own application packages or to the package code:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">count(): int<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">getIterator(): Traversable<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">getSize(): int<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">jsonSerialize(): array<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">offsetExists($key): bool<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">offsetGet($key): mixed<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">offsetSet($key, $value): void<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">offsetUnset($key): void<\/span><span style=\"font-weight: 400;\"><br \/>\n<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400;\">Now, check if Laravel 9 has been updated.<\/span><\/p>\n<hr \/>\n<p>If you are a newbie or want to migrate to Laravel to build your applications, a reliable <a href=\"https:\/\/www.hostingseekers.com\/category\/web-hosting\/laravel-hosting\">Laravel hosting provider<\/a> is all you need! Explore &amp; choose from our list of top-rated Laravel hosting companies.<\/p>\n<h4 id=\"047b\" class=\"ht hu dt hv b hw hx hy hz ia ib ic id ie if ig ih ii ij ik il im in io ip iq dl eq\"><em>If you enjoyed reading this news, you are surely going to cherish these too \u2013<\/em><\/h4>\n<ul>\n<li><a href=\"https:\/\/www.hostingseekers.com\/blog\/cloud-infrastructure-market-grew-up\/\">Cloud Infrastructure Expanded Its Market by 37%, Grew To \u00a3131bn in 2021<\/a><\/li>\n<li><a href=\"https:\/\/www.hostingseekers.com\/blog\/solarwinds-database-performance-analyzer-is-out-now\/\">SolarWinds Database Performance Analyzer is now available in Azure Marketplace<\/a><\/li>\n<li><a href=\"https:\/\/www.hostingseekers.com\/blog\/biggest-ever-ddos-attack-terminated-by-microsoft\/\">Biggest-Ever DDoS Attack In History Terminated by Microsoft<\/a><\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>The newly released Laravel 9 is highly scalable and comes with so many new features, including a minimum PHP v8.0&hellip; <a class=\"more-link\" href=\"https:\/\/www.hostingseekers.com\/blog\/laravel-9-released-what-should-you-expect\/\">Continue reading <span class=\"screen-reader-text\">Laravel 9 Released: What Should You Expect?<\/span><\/a><\/p>\n","protected":false},"author":2,"featured_media":7066,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[238],"tags":[],"class_list":["post-7459","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-news","entry"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.3 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>New Laravel 9 released with brand new features |HostingSeekers<\/title>\n<meta name=\"description\" content=\"The most popular PHP framework Laravel has released its newest version - Laravel 9 with improvised features like minimum PHP requirements, a new query builder interface, etc.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.hostingseekers.com\/blog\/laravel-9-released-what-should-you-expect\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"New Laravel 9 released with brand new features |HostingSeekers\" \/>\n<meta property=\"og:description\" content=\"The most popular PHP framework Laravel has released its newest version - Laravel 9 with improvised features like minimum PHP requirements, a new query builder interface, etc.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.hostingseekers.com\/blog\/laravel-9-released-what-should-you-expect\/\" \/>\n<meta property=\"og:site_name\" content=\"Hostingseekers\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/hostingseekers\" \/>\n<meta property=\"article:published_time\" content=\"2022-02-10T18:12:43+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-03-06T11:35:28+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.hostingseekers.com\/blog\/wp-content\/uploads\/2022\/02\/Laravel-9.0-released.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"1200\" \/>\n\t<meta property=\"og:image:height\" content=\"675\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"manvinder Singh\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@Hostingseekers1\" \/>\n<meta name=\"twitter:site\" content=\"@Hostingseekers1\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"manvinder Singh\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"4 minutes\" \/>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"New Laravel 9 released with brand new features |HostingSeekers","description":"The most popular PHP framework Laravel has released its newest version - Laravel 9 with improvised features like minimum PHP requirements, a new query builder interface, etc.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.hostingseekers.com\/blog\/laravel-9-released-what-should-you-expect\/","og_locale":"en_US","og_type":"article","og_title":"New Laravel 9 released with brand new features |HostingSeekers","og_description":"The most popular PHP framework Laravel has released its newest version - Laravel 9 with improvised features like minimum PHP requirements, a new query builder interface, etc.","og_url":"https:\/\/www.hostingseekers.com\/blog\/laravel-9-released-what-should-you-expect\/","og_site_name":"Hostingseekers","article_publisher":"https:\/\/www.facebook.com\/hostingseekers","article_published_time":"2022-02-10T18:12:43+00:00","article_modified_time":"2025-03-06T11:35:28+00:00","og_image":[{"width":1200,"height":675,"url":"https:\/\/www.hostingseekers.com\/blog\/wp-content\/uploads\/2022\/02\/Laravel-9.0-released.jpg","type":"image\/jpeg"}],"author":"manvinder Singh","twitter_card":"summary_large_image","twitter_creator":"@Hostingseekers1","twitter_site":"@Hostingseekers1","twitter_misc":{"Written by":"manvinder Singh","Est. reading time":"4 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.hostingseekers.com\/blog\/laravel-9-released-what-should-you-expect\/#article","isPartOf":{"@id":"https:\/\/www.hostingseekers.com\/blog\/laravel-9-released-what-should-you-expect\/"},"author":{"name":"manvinder Singh","@id":"https:\/\/www.hostingseekers.com\/blog\/#\/schema\/person\/76bc9258cab3c5bfe0237d3e290b13ea"},"headline":"Laravel 9 Released: What Should You Expect?","datePublished":"2022-02-10T18:12:43+00:00","dateModified":"2025-03-06T11:35:28+00:00","mainEntityOfPage":{"@id":"https:\/\/www.hostingseekers.com\/blog\/laravel-9-released-what-should-you-expect\/"},"wordCount":723,"commentCount":0,"publisher":{"@id":"https:\/\/www.hostingseekers.com\/blog\/#organization"},"image":{"@id":"https:\/\/www.hostingseekers.com\/blog\/laravel-9-released-what-should-you-expect\/#primaryimage"},"thumbnailUrl":"https:\/\/www.hostingseekers.com\/blog\/wp-content\/uploads\/2022\/02\/Laravel-9.0-released.jpg","articleSection":["News"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.hostingseekers.com\/blog\/laravel-9-released-what-should-you-expect\/#respond"]}],"copyrightYear":"2022","copyrightHolder":{"@id":"https:\/\/www.hostingseekers.com\/blog\/#organization"}},{"@type":"WebPage","@id":"https:\/\/www.hostingseekers.com\/blog\/laravel-9-released-what-should-you-expect\/","url":"https:\/\/www.hostingseekers.com\/blog\/laravel-9-released-what-should-you-expect\/","name":"New Laravel 9 released with brand new features |HostingSeekers","isPartOf":{"@id":"https:\/\/www.hostingseekers.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.hostingseekers.com\/blog\/laravel-9-released-what-should-you-expect\/#primaryimage"},"image":{"@id":"https:\/\/www.hostingseekers.com\/blog\/laravel-9-released-what-should-you-expect\/#primaryimage"},"thumbnailUrl":"https:\/\/www.hostingseekers.com\/blog\/wp-content\/uploads\/2022\/02\/Laravel-9.0-released.jpg","datePublished":"2022-02-10T18:12:43+00:00","dateModified":"2025-03-06T11:35:28+00:00","description":"The most popular PHP framework Laravel has released its newest version - Laravel 9 with improvised features like minimum PHP requirements, a new query builder interface, etc.","breadcrumb":{"@id":"https:\/\/www.hostingseekers.com\/blog\/laravel-9-released-what-should-you-expect\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.hostingseekers.com\/blog\/laravel-9-released-what-should-you-expect\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.hostingseekers.com\/blog\/laravel-9-released-what-should-you-expect\/#primaryimage","url":"https:\/\/www.hostingseekers.com\/blog\/wp-content\/uploads\/2022\/02\/Laravel-9.0-released.jpg","contentUrl":"https:\/\/www.hostingseekers.com\/blog\/wp-content\/uploads\/2022\/02\/Laravel-9.0-released.jpg","width":1200,"height":675,"caption":"Laravel 9.0 released"},{"@type":"BreadcrumbList","@id":"https:\/\/www.hostingseekers.com\/blog\/laravel-9-released-what-should-you-expect\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.hostingseekers.com\/blog\/"},{"@type":"ListItem","position":2,"name":"Laravel 9 Released: What Should You Expect?"}]},{"@type":"WebSite","@id":"https:\/\/www.hostingseekers.com\/blog\/#website","url":"https:\/\/www.hostingseekers.com\/blog\/","name":"Hostingseekers","description":"Hostingseekers","publisher":{"@id":"https:\/\/www.hostingseekers.com\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.hostingseekers.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.hostingseekers.com\/blog\/#organization","name":"HostingSeekers Pvt. Ltd.","url":"https:\/\/www.hostingseekers.com\/blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.hostingseekers.com\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/www.hostingseekers.com\/blog\/wp-content\/uploads\/2025\/04\/Hosting-Seekers-Logo.png","contentUrl":"https:\/\/www.hostingseekers.com\/blog\/wp-content\/uploads\/2025\/04\/Hosting-Seekers-Logo.png","width":451,"height":520,"caption":"HostingSeekers Pvt. Ltd."},"image":{"@id":"https:\/\/www.hostingseekers.com\/blog\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/hostingseekers","https:\/\/x.com\/Hostingseekers1","https:\/\/www.linkedin.com\/company\/hostingseekers\/","https:\/\/www.instagram.com\/hostingseekers\/"]},{"@type":"Person","@id":"https:\/\/www.hostingseekers.com\/blog\/#\/schema\/person\/76bc9258cab3c5bfe0237d3e290b13ea","name":"manvinder Singh","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/4373df1ab2b4f1e40b27df8913e40d494a7fd38d128e0ac30e9f7406a4f96e91?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/4373df1ab2b4f1e40b27df8913e40d494a7fd38d128e0ac30e9f7406a4f96e91?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/4373df1ab2b4f1e40b27df8913e40d494a7fd38d128e0ac30e9f7406a4f96e91?s=96&d=mm&r=g","caption":"manvinder Singh"},"description":"Manvinder Singh is the Founder and CEO of HostingSeekers, an award-winning go-to-directory for all things hosting. Our team conducts extensive research to filter the top solution providers, enabling visitors to effortlessly pick the one that perfectly suits their needs. We are one of the fastest growing web directories, with 500+ global companies currently listed on our platform.","sameAs":["https:\/\/www.hostingseekers.com","https:\/\/www.linkedin.com\/in\/manvinder-singh\/"],"url":"https:\/\/www.hostingseekers.com\/blog\/author\/seodeveloper\/"}]}},"_links":{"self":[{"href":"https:\/\/www.hostingseekers.com\/blog\/wp-json\/wp\/v2\/posts\/7459","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.hostingseekers.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.hostingseekers.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.hostingseekers.com\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.hostingseekers.com\/blog\/wp-json\/wp\/v2\/comments?post=7459"}],"version-history":[{"count":2,"href":"https:\/\/www.hostingseekers.com\/blog\/wp-json\/wp\/v2\/posts\/7459\/revisions"}],"predecessor-version":[{"id":35444,"href":"https:\/\/www.hostingseekers.com\/blog\/wp-json\/wp\/v2\/posts\/7459\/revisions\/35444"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.hostingseekers.com\/blog\/wp-json\/wp\/v2\/media\/7066"}],"wp:attachment":[{"href":"https:\/\/www.hostingseekers.com\/blog\/wp-json\/wp\/v2\/media?parent=7459"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.hostingseekers.com\/blog\/wp-json\/wp\/v2\/categories?post=7459"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.hostingseekers.com\/blog\/wp-json\/wp\/v2\/tags?post=7459"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}