My Setup

I added a stripe checkout redirect from my craft website using Stripe Checkout so I can accept payments from customers using payments handled by stripe.

In simple, I use AJAX on the frontend to send a request to a controller endpoint I created via a Custom Module, that controller then handles creating a stripe checkout session which redirects the user to a Stripe Created Payment page (see screenshot below). This all works great.

The Problem

The problem arises after the user fills out the stripe payment form (hosted on a stripe URL) and completes payment. I configured Stripe to redirect the user back to my website BASE_URL/success.html. However, this redirect results in a 403 error "Request forbidden by administrative rules." (See screenshot below). However, if I simply type in BASE_URL/success.html into my browser and hit enter, the page loads as I expect. Only when the redirect comes from Stripe does the problem arise.

My Question

What CRAFT or PHP rules are blocking this redirect from stripe? Locally, it works perfectly, but as soon as I deploy to DEV (hosted on HYPERLANE), the 403 error occurs. I feel like I am missing some sort of permission, or redirect rule that is unique to live hosted environments, which is not enforced on my local.

Note: This may not be isolated to Stripe redirects, it could be that any redirects to my Craft Website from external websites return this same error.

Thanks in advance for any help you can provide!

Stripe Checkout Page

403 error on redirect from website


1 Answer 1


Update: By using http instead of https in the redirect URL. Stripe is able to successfully redirect back to my website.

It would be nice to avoid this workaround and understand why using https in the redirect URL results in the request being blocked.

Your Answer

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

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