# Login Required when accessing protected routes

**URL:** <https://community.auth0.com/t/login-required-when-accessing-protected-routes/119853>\
**Category:** Get Help\
**Tags:** new-universal-login-experience, login-experience\
**Created:** [October 31, 2023, 10:15am UTC](https://community.auth0.com/t/login-required-when-accessing-protected-routes/119853 "2023-10-31T10:15:19Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![sayanth-perfagents](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/sayanth-perfagents/32/33466_2.png) [@sayanth-perfagents](https://community.auth0.com/u/sayanth-perfagents)\
**Post date:** [October 31, 2023, 10:15am UTC](https://community.auth0.com/t/login-required-when-accessing-protected-routes/119853/1 "2023-10-31T10:15:19Z")

</div>

I used Auth0 with my Vue.js app through the auth-vue SDK. I set up Auth0 and added a middleware authGuard for protected routesof the app.

But, I have a problem:

1. When a user tries to go to a secure page without logging in, like “[https://localhost:8080/dashboard/list,](https://localhost:8080/dashboard/list,)”
2. Instead of going to the login page, they see a blank screen, and in the console, there’s an error message saying, “Login required.”

In the Auth0 logs, there’s an error that says “silent authentication failed.”

```auto
script.js:1 Error: Login required
    at new t (auth0-spa-js.production.esm.js:1:1)
    at t.fromPayload (auth0-spa-js.production.esm.js:1:1)
    at r (auth0-spa-js.production.esm.js:1:1)

```

---

<div class="post-metadata">

**Author:** ![dan.woda](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/dan.woda/32/18340_2.png) [@dan.woda](https://community.auth0.com/u/dan.woda)\
**Post date:** [November 6, 2023, 4:59pm UTC](https://community.auth0.com/t/login-required-when-accessing-protected-routes/119853/3 "2023-11-06T16:59:54Z")

</div>

Hi @sayanth-perfagents,

Could you please share some code snippets of your implementation?

---

<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:** [November 20, 2023, 5:00pm UTC](https://community.auth0.com/t/login-required-when-accessing-protected-routes/119853/4 "2023-11-20T17:00:54Z")

</div>

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