# Access\_token expires in 24hours for newly created users

**URL:** <https://community.auth0.com/t/access-token-expires-in-24hours-for-newly-created-users/35991>\
**Category:** Get Help\
**Tags:** api, auth0\
**Created:** [January 8, 2020, 3:54pm UTC](https://community.auth0.com/t/access-token-expires-in-24hours-for-newly-created-users/35991 "2020-01-08T15:54:59Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![nihalilu](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/nihalilu/32/5460_2.png) [@nihalilu](https://community.auth0.com/u/nihalilu)\
**Post date:** [January 8, 2020, 3:54pm UTC](https://community.auth0.com/t/access-token-expires-in-24hours-for-newly-created-users/35991/1 "2020-01-08T15:54:59Z")

</div>

Hi, For our application when we any new user login to the application using auth0, the access\_token gets expired in 24 hours but at the same time, access\_token does not expire for users who logged in more than a few weeks ago. Is it due to any new changes on auth0 ?

---

<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:** [January 8, 2020, 10:53pm UTC](https://community.auth0.com/t/access-token-expires-in-24hours-for-newly-created-users/35991/3 "2020-01-08T22:53:11Z")

</div>

Hi @nihalilu,

Access token expiration should conform to this schedule:

> **[Access Tokens](https://auth0.com/docs/secure/tokens/access-tokens)**
>
> Describes how access tokens are used in token-based authentication to allow an application to access an API after a user successfully authenticates and authorizes access.

If you think you have found a bug, please let us know more about the setup you are using (what framework/language, how to reproduce)

Thanks,  
Dan

---

<div class="post-metadata">

**Author:** ![nihalilu](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/nihalilu/32/5460_2.png) [@nihalilu](https://community.auth0.com/u/nihalilu)\
**Post date:** [January 8, 2020, 11:27pm UTC](https://community.auth0.com/t/access-token-expires-in-24hours-for-newly-created-users/35991/4 "2020-01-08T23:27:58Z")

</div>

I have modified token expiration time from 86400 seconds to maximum but still same case the token is getting expired automatically in 24 hours. This is something automatically happened, it was working fine until few weeks back.

---

<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:** [January 8, 2020, 11:46pm UTC](https://community.auth0.com/t/access-token-expires-in-24hours-for-newly-created-users/35991/5 "2020-01-08T23:46:13Z")

</div>

Please let us know more about the setup you are using (what framework/language, how to reproduce).

---

<div class="post-metadata">

**Author:** ![nihalilu](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/nihalilu/32/5460_2.png) [@nihalilu](https://community.auth0.com/u/nihalilu)\
**Post date:** [January 9, 2020, 9:20am UTC](https://community.auth0.com/t/access-token-expires-in-24hours-for-newly-created-users/35991/7 "2020-01-09T09:20:53Z")

</div>

This issue occurs after 24hours of account linking with alexa or action on google.

My understanding is this is unable to refresh token. This was working fine until few weeks ago. Then suddenly this started occurring. Is it because of any changes at Auth0 ?

Here is Authorization url-

https://[my-tenant].auth0.com/authorize?prompt=login

Token url-

https://[my-tenant].auth0.com/oauth/token

Attached screenshot of scopes being used and linking type is Authorization Code flow.

 ![image](https://global.discourse-cdn.com/auth0/original/3X/4/7/4707509ab0e8b803f27382b0c812169d189647b7.jpeg) ![image](https://global.discourse-cdn.com/auth0/original/3X/b/5/b5ceaae140b913c7f954dbc3405d472583099f28.jpeg)

---

<div class="post-metadata">

**Author:** ![nihalilu](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/nihalilu/32/5460_2.png) [@nihalilu](https://community.auth0.com/u/nihalilu)\
**Post date:** [January 10, 2020, 6:42pm UTC](https://community.auth0.com/t/access-token-expires-in-24hours-for-newly-created-users/35991/8 "2020-01-10T18:42:01Z")

</div>

Is this because of any new changes at auth0 ?

---

<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:** [January 10, 2020, 10:10pm UTC](https://community.auth0.com/t/access-token-expires-in-24hours-for-newly-created-users/35991/9 "2020-01-10T22:10:47Z")

</div>

I am not seeing any global changes that would’ve caused token expiration to be shortened. Which means this is likely either a bug or misconfig.

Please send me your tenant name in a DM.

I would like to ask again that you provide the information that I initially requested. **Please let us know more about the setup you are using (what framework/language/SDK/Quickstarts/tutorials you used to build your app).**

In addition, you can see your token expiration setting in your API settings:

> **[Update Access Token Lifetime](https://auth0.com/docs/secure/tokens/access-tokens/update-access-token-lifetime)**
>
> Describes how to update the access token lifetime for an API using the Auth0 Dashboard.

---

<div class="post-metadata">

**Author:** ![nihalilu](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/nihalilu/32/5460_2.png) [@nihalilu](https://community.auth0.com/u/nihalilu)\
**Post date:** [January 11, 2020, 7:33am UTC](https://community.auth0.com/t/access-token-expires-in-24hours-for-newly-created-users/35991/10 "2020-01-11T07:33:06Z")

</div>

We are using this for Account linking with Alexa and Google assistant.  
Framework which we are using is **[https://cdn.auth0.com/js/auth0/9.11.2/auth0.min.js](https://cdn.auth0.com/js/auth0/9.11.2/auth0.min.js)**.  
Also, I tried with **[https://cdn.auth0.com/js/lock/11.20/lock.min.js](https://cdn.auth0.com/js/lock/11.20/lock.min.js)** but the issue was persisting continued.

To get the userinfo we have written our code in C#, which gets the userinfo by sending bearer token at **https://[my-tenant].auth0.com/userinfo**  
I shared tenant name in DM.

**Note-** This issue started few weeks back, earlier it was working fine.

---

<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:** [January 13, 2020, 10:06pm UTC](https://community.auth0.com/t/access-token-expires-in-24hours-for-newly-created-users/35991/11 "2020-01-13T22:06:34Z")

</div>

Everything in the tenant looks normal right now. Are you requesting a token with your api as the audience? Or just a standard token for the userinfo endpoint? If you post your code that could be helpful.

Can you provide me with a [HAR](https://auth0.com/docs/troubleshoot/har) file **via DM** of a login from one of the older users with the longer-lived token?

---

<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:** [January 31, 2020, 9:20pm UTC](https://community.auth0.com/t/access-token-expires-in-24hours-for-newly-created-users/35991/12 "2020-01-31T21:20:34Z")

</div>

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