I have a site that is using Craft CMS headless and React. There are a few forms that need to post to controllers but I'm not sure how to set up the CSRF tokens and keep it secure.

Can anyone advise me on how to manage this?

1 Answer 1


Take a look at the craft documentation for this: https://craftcms.com/guides/enabling-csrf-protection#updating-your-javascript it should point you in the right direction.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.