Personally I use this package https://github.com/spatie/laravel-permission
It can do what you need and a lot more, and is well tested
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
Project I'm working on requires some roles nothing too complex roughly 5-6 different roles based on title (Members, Staff, Admin, Editor, Financier) should I just crate a table with available rolls and join them? There might be a scenario where user can have multiple roles.
Would that be best way to do this?
I would like to access these properties in few places eg. Routes file if->auth->hasRole(editor)
In controller similar thing user->hasRole
Would like your guys' feedback and suggested implementation Thanks
Please or to participate in this conversation.