When using Laravel, you’ll notice that there are many versions of it (The latest is version 9 by the time of writing this blog). Which one should you use? The latest one or the previous versions?
When choosing which Laravel version to use, preferably you should stick with the latest stable version. But, if you have specific conditions (e.g. client request), you should use whatever version is needed or requested.
If you’re doing a freelance project for a company that uses an older version of Laravel for example, then you should follow what the client requests. But, if possible, you can suggest them to consider them using the latest versions and tell them the benefits of keeping up to date.
But if you’re learning Laravel, you should always keep up to date with the latest version as it has new features, better support, improved performance and many more benefits. As a programmer, you’d want to keep up with the latest version of languages, frameworks and tools.
If you stick with old versions, it would still work, but there might be deprecated packages. Well, it might not harm your project, but new versions would probably perform better. But if you think certain old packages are better, you may stick to it.
Another point to consider, is you environment. Since Laravel 9 needs PHP 8 and above, do you have it? Does your hosting support PHP 8? Some things you can find the solution, but there are certain conditions where you are stuck with maybe Laravel 8 or older versions.
In the end, you should judge for yourself which version you should use. It all comes down to your preference, which version you are most comfortable with and what it is for.
How to know which Laravel version is the latest?
If you want to know whether your Laravel version is the latest, you can simply check the Laravel Documentation and see the top right corner and you should be able to see a version with a number like 9.x for example, and that is the latest stable version.
Should I update published Laravel projects?
If it is still running smoothly and it is still a quite recent version, you should leave it as it is. This article does an amazing job explaining why you should not upgrade existing Laravel projects. But if you are starting a new project, you should definitely use the latest versions.
That’s all I can suggest you as to which Laravel version you should use (the latest!). You know what’s best for your project and what your project needs. Just don’t keep using older version because you are lazy to update or learn the newest version. Keep learning and you’re good to go!
Now that you understand more about Laravel, if you’re looking for where to host your Laravel App, I recommend Cloudways. It is compatible, fast, reliable and has a specific option for Laravel. There are also tons of resources about Laravel hosting on Cloudways. Go ahead and check it out!
If you’re looking to refresh your PHP skill, you can try Codecademy’s free PHP course. Go ahead and check out the syllabus to see if it fits you. If you’re interested, go and try it for free!
If you are interested about other topics in Laravel, you can check :
- How to Set Up Laravel in Windows
- Laravel Project Structure
- How to Get Location in Laravel Without Google Maps API
- How to Remove a Package in Laravel
- CDN VS Local in Laravel
- How to Integrate AdminLTE With Laravel