How to integrate LiqPay with Laravel and stop losing sales at checkout
Payment failures at checkout cost Ukrainian online stores millions of hryvnias every year. A properly integrated LiqPay gateway — built on Laravel — eliminates redirect errors, handles callbacks reliably, and keeps reconciliation data clean for your accounting team.
Why LiqPay, and why Laravel
LiqPay processes Visa, Mastercard, Apple Pay, and Google Pay with a single API. It is the default choice for Ukrainian merchants because it settles in UAH, EUR, and USD without currency conversion headaches.
Laravel makes the integration maintainable. Controllers stay thin, payment events flow through jobs and queues, and webhook handling lives in a dedicated LiqPayController — not buried in a monolithic OrderController.
The integration pattern
A production-grade LiqPay flow in Laravel has four components:
- Checkout action — generates a signed
data+signaturepayload and passes it to the payment form. - Redirect handler — receives the user back from LiqPay and displays an order-status page without confirming payment server-side (that is the callback's job).
- Webhook endpoint — a POST route protected by signature verification that updates
orders.payment_statusand fires anOrderPaidevent. - Reconciliation job — a scheduled Artisan command that calls
LiqPay::paymentStatus()for orders stuck inpendinglonger than 15 minutes.
// Verify LiqPay signature before trusting any callback
$expectedSignature = base64_encode(
sha1($privateKey . $data . $privateKey, true)
);
abort_if($signature !== $expectedSignature, 403); The signature verification step is critical: always validate the HMAC before trusting any callback data. Skipping it opens your store to forged payment confirmations.
Business outcomes you can measure
- Zero double-charges — idempotency keys on the webhook handler prevent duplicate
OrderPaidevents even when LiqPay retries the callback. - Faster reconciliation — the scheduled job flags discrepancies automatically, cutting finance team overhead by roughly 2 hours per week.
- Higher conversion — a native checkout without third-party redirects typically lifts payment completion rates by 8–12%.
What MaxiMoruM delivers
We integrate LiqPay into Laravel, WordPress (WooCommerce), and OpenCart projects with full webhook security, retry logic, and accounting export. Implementation takes 3–5 business days depending on existing order-management complexity.
Ready to stop losing sales at checkout? Visit maximorum.com to discuss your integration.