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

petercontrains's avatar

TokenMismatchException

This is my error:

(1/1) TokenMismatchException in VerifyCsrfToken.php (line 68) at VerifyCsrfToken->handle(object(Request), object(Closure)) in Pipeline.php (line 148)

How to know which view or part of the view or controller need the token?

In the views is {{crsf_field}}, Do the controllers carry token?

0 likes
2 replies
ekpono's avatar

put this in the head tag <meta name="csrf-token" content="{{ csrf_token() }}"> and use this in your form @csrf

Please or to participate in this conversation.