Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

lewisbhs's avatar

Check if Subscription is Valid

Hi,

I was wondering if there was a way in blade and in laravel in general to check if the users subscription has not been renewed/is cancelled.

I've found solutions of doing this in Vue, but vue is only being used for the Login, Register & Settings pages.

Thanks in advance.

0 likes
2 replies
cristo's avatar

Check out Subscription class in Laravel Cashier. It has plenty of methods, such as valid(), active(), and cancelled(). You can also check user's status directly with the help of Billable trait: $user->subscribed() which returns true or false.

lewisbhs's avatar

Thank you @cristo, I've got that working but had another question. How can I get the next renewal date from Spark? I've checked the database, it is not there - only "ends_at" is.

Please or to participate in this conversation.