# Cached URL in Post-login redirect flow

**URL:** <https://community.auth0.com/t/cached-url-in-post-login-redirect-flow/186416>\
**Category:** Get Help\
**Tags:** login-experience, new-universal-login-experience\
**Created:** [May 7, 2025, 10:14am UTC](https://community.auth0.com/t/cached-url-in-post-login-redirect-flow/186416 "2025-05-07T10:14:03Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![planger](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/planger/32/60075_2.png) [@planger](https://community.auth0.com/u/planger)\
**Post date:** [May 7, 2025, 10:14am UTC](https://community.auth0.com/t/cached-url-in-post-login-redirect-flow/186416/1 "2025-05-07T10:14:03Z")

</div>

During the development of post-login trigger the redirect URL was defined as `http://localhost:....`, after the development was done the property got changed to the actual URL of an application, even tough the redirect URL is cached, most probably on Auth0 side.

To sum up: user is still redirected to the localhost, if the structure of the route is changed (in the actions itself), fe.: from `https://{domain}/some-route` to `https://{domain}/en/some-route` the redirect works as intended.

That was tested on multiple devices, also on the ones that weren’t used during the development, so the URL cannot be cached on the client side

What steps should be taken to avoid that behaviour?

---

<div class="post-metadata">

**Author:** ![rueben.tiow](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/rueben.tiow/32/11646_2.png) [@rueben.tiow](https://community.auth0.com/u/rueben.tiow)\
**Post date:** [May 7, 2025, 5:31pm UTC](https://community.auth0.com/t/cached-url-in-post-login-redirect-flow/186416/3 "2025-05-07T17:31:51Z")

</div>

Hi @planger,

When using `api.redirect.sendUserTo()` in a Post-Login, the user is redirected to the specified URL, and Auth0 does not cache it.

If the user is still being redirected to localhost, I recommend checking your network activity to verify the requests and check them against the [Dashboard Logs](https://manage.auth0.com/#/logs). I would also check that the `redirect_uri` of your `/authorize` request does not point to `localhost` either.

It might also be helpful to include some console log statements in the Action scripts and monitor the output in the [Action Logs](https://manage.auth0.com/#/action-logs) during a login flow.

Let me know if you continue experiencing issues.

Thanks,  
Rueben

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/auth0/original/3X/b/5/b560f266932fcce5d57f09a6595bd50518cae3f3.jpeg) [@system](https://community.auth0.com/u/system)\
**Post date:** [May 21, 2025, 5:32pm UTC](https://community.auth0.com/t/cached-url-in-post-login-redirect-flow/186416/4 "2025-05-21T17:32:14Z")

</div>

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
