← Back to discussions

Razorpay payment succeeds but doesn't return to the app

KKartik MPublished 6/29/20265902 views2 comments

We integrated Razorpay checkout into our ecommerce site. In Chrome mobile, the payment flows smoothly: user pays via UPI/netbanking, Razorpay redirects back to our payment success page.

Inside the WebView, after the user completes the UPI payment in Google Pay/PhonePe, the transaction succeeds but the redirect gets stuck, leaving a blank page. How can we make it return to the app and load the success URL?

2 Comments

NNoopur6/29/2026

Also, ensure that your redirect page does not attempt to break out of the iframe or use window.close(). WebViews don't have multiple tabs or windows by default unless you support onCreateWindow. Change your checkout flow to use standard AJAX callbacks or direct redirection in the same page window.

SSia Singh6/29/2026

This is a common issue with UPI deep links. When the user transitions from the UPI app back to the WebView app, the WebView sometimes loses context or fails to handle the custom payment schemes.
You need to implement a fallback handler in your redirect URL. Ensure the redirect is a standard HTTPS URL rather than a custom scheme, so the WebView navigation delegate intercepts it cleanly.

Please log in to reply.
WhatsApp