# Redirect after Login

**URL:** <https://forum.shopware.com/t/redirect-after-login/72116>\
**Category:** Administration (EN)\
**Created:** [15. Januar 2021 um 09:24 UTC](https://forum.shopware.com/t/redirect-after-login/72116 "2021-01-15T09:24:15Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![MKFS](https://avatars.discourse-cdn.com/v4/letter/m/3be4f8/32.png) [@MKFS](https://forum.shopware.com/u/MKFS)\
**Post date:** [15. Januar 2021 um 09:24 UTC](https://forum.shopware.com/t/redirect-after-login/72116/1 "2021-01-15T09:24:15Z")

</div>

Hi Community,

we want to enable our customers beeing redirected to the page they were viewing before after they logged in and not to their user profile. I don’t find that anywhere in the doc - can anyone point to me where I can enable this?

Thanks a lot in advance!

MKFS

---

<div class="post-metadata">

**Author:** ![L.T](https://avatars.discourse-cdn.com/v4/letter/l/ccd318/32.png) [@L.T](https://forum.shopware.com/u/L.T)\
**Post date:** [27. April 2021 um 12:34 UTC](https://forum.shopware.com/t/redirect-after-login/72116/2 "2021-04-27T12:34:55Z")

</div>

How is it possible that simple questions like that go unanswered? The documentation is really poor on a lot of topics. 🤔

---

<div class="post-metadata">

**Author:** ![josemanuel](https://avatars.discourse-cdn.com/v4/letter/j/34f0e0/32.png) [@josemanuel](https://forum.shopware.com/u/josemanuel)\
**Post date:** [11. Juli 2022 um 15:01 UTC](https://forum.shopware.com/t/redirect-after-login/72116/3 "2022-07-11T15:01:37Z")

</div>

I want also to know how to redirect after a valid custom login. to accoun/login  
It worked for me in shopware 5.  
but I am recoding the plugin I made for shopware 6 ( code must be different )

I managed to redirect using :

```
        use \Symfony\Component\HttpFoundation\RedirectResponse;

       $response = new RedirectResponse('frontend.account.login.page');
        $response->send();

```

but I want to use My ContextToken (I am already logged)  
to see the green screen (Logged) in the view. but it appears as If I am not logged…

I make a request to ‚[http://localhost/store-api/account/login](http://localhost/store-api/account/login)‘, ( that returns OK. token)

from localhost/voxelcare-login-control. and then I must go to  
localhost/admin/login ( with the green screen of logged)
