# Logout returnTo was not working

**URL:** <https://community.auth0.com/t/logout-returnto-was-not-working/185287>\
**Category:** Get Help\
**Tags:** other, missing-category\
**Created:** [April 10, 2025, 11:55am UTC](https://community.auth0.com/t/logout-returnto-was-not-working/185287 "2025-04-10T11:55:22Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![das95sankaram](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/das95sankaram/32/74180_2.png) [@das95sankaram](https://community.auth0.com/u/das95sankaram)\
**Post date:** [April 10, 2025, 11:55am UTC](https://community.auth0.com/t/logout-returnto-was-not-working/185287/1 "2025-04-10T11:55:22Z")

</div>

I have configured the logout URL -  
“[https://dev-xxxx.us.auth0.com/v2/logout?returnTo=http%3A%2F%2Flocalhost%3A3000&client\_id=xxclient\_idxxx](https://dev-xxxx.us.auth0.com/v2/logout?returnTo=http%3A%2F%2Flocalhost%3A3000&client_id=xxclient_idxxx)”.  
But still showing error.

onClick={() =\> {  
router.push(“[http://localhost:8080/logout](http://localhost:8080/logout)”);  
}} //useRouter from next/navigation

const config = { routes: {  
postLogoutRedirect: process.env.CLIENT\_URL, }

CLIENT\_URL=[http://localhost:3000](http://localhost:3000)

 ![2025-04-10](https://global.discourse-cdn.com/auth0/original/3X/0/6/0621a7e1d0e8e6e7bedcdf485cee086336520815.png)  
 ![2025-04-10 (1)](https://global.discourse-cdn.com/auth0/original/3X/2/6/26666da59a5aa97d6e46612fc47576b793bb63cd.png)  
 ![2025-04-10 (2)](https://global.discourse-cdn.com/auth0/original/3X/8/2/824e7bfa02902361073881d15215df9b7294d239.png)

---

<div class="post-metadata">

**Author:** ![vlad.murarasu](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/vlad.murarasu/32/72793_2.png) [@vlad.murarasu](https://community.auth0.com/u/vlad.murarasu)\
**Post date:** [April 10, 2025, 2:12pm UTC](https://community.auth0.com/t/logout-returnto-was-not-working/185287/3 "2025-04-10T14:12:44Z")

</div>

Hi @das95sankaram,

Welcome to the Auth0 Community!

The error message specifies that the “[http://localhost:3000](http://localhost:3000)” URL is not set up inside the Allowed Logout URLs. In the screenshot you provided, the Allowed Logout URL seems to be “[http://localhost:3001](http://localhost:3001)”. The correct URL needs to be inputted.

If you have any other questions, feel free to reach out.

Have a good one,  
Vlad

---

<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:** [April 24, 2025, 2:13pm UTC](https://community.auth0.com/t/logout-returnto-was-not-working/185287/4 "2025-04-24T14:13:34Z")

</div>

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