Get Free Audit

How To Redirect Users To Another Page After Login In Prestashop

Mar 14, 2013

13169 Alex Simonchik

The page, where a customer is redirected to after login, is determined by the function processSubmitAccount of the controller AuthController. In case we need to change the function behavior, we would need to rewrite it. It is also possible to use the hook actionCustomerAccountAdd, but this method is good for new customers only.

The function Tools::redirect(), which serves as a certain wrapper for the construction header(‘Location:’.$url); , is specifically responsible for the redirect. In this function it is used 7 times.

So, to redirect a customer to some other page you just need to change the argument of the function Tools::redirect.

Andrey Dubina
Partner With Us Looking for a partner to grow your business? We are the right company to bring your webstore to success. Talk to Andrey


  1. Hi good article!

    But this is to redirect when you create a new account. To change redirections after login the function to search for is called “processSubmitLogin”.

  2. So the path where to do that shoud be… yourprestashop/controllers/front/AuthController.php :P

  3. Hi Alex, thank you for a very nice explanation of the redirect problem in Prestashop.

    I would like to ask about redirection after clicking the SubmitLogin and SubmitGuestAccount buttons ( in case of errors (e.g. when a customer forgets to fill in a field). Where can this redirection be found? Thank you very much. Jana

Post a new comment

BelVG Newsletter
Subscribe to our mailing list and get interesting stuff and updates to your email inbox.
Email *