<p>Currently (as of Craft 3.0), it will affect entry and category share links.  Some additional things might be using it in the upcoming 3.1 and plugins are free to use it for whatever they want.</p>

<p>For example, in Commerce 2, it is used for creating product preview share links.</p>

CC BY-SA 4.0
2021-01-11T16:47:21.370Z
Thanks for clarifying. Has this changed significantly in 3.1+, Brad? It'd be helpful to understand the scope of `defaultTokenDuration` in the documentation.
Carrie Kendall
CC BY-SA 4.0
2018-11-17T01:16:47.890Z
2018-11-17T01:16:47.890Z
Brad Bell
<p>Per <a href="https://craftcms.stackexchange.com/a/21986/5072">this answer</a>, configuring <code>defaultTokenDuration</code> is the way to change the lifespan of hidden entries' share links from the default 24 hours. The v2 docs describes this as affecting "system tokens" but no further explanation of system tokens is provided. The v3 docs refers simply to "tokens."</p>

<p>[edit: I believe one other thing this controls is the lifespan of password reset tokens.]</p>

<p>I'd like to increase the lifespan of draft entries' share links, but wonder what other consequences I should take into account before changing <code>defaultTokenDuration</code>. What all does it affect?</p>

<config><token>
What does defaultTokenDuration affect besides hidden entries' share links?
# What does defaultTokenDuration affect besides hidden entries' share links?

(Asked by: username_0 on 2018-10-03)

Per [this answer](https://craftcms.stackexchange.com/a/21986/5072), configuring `defaultTokenDuration` is the way to change the lifespan of hidden entries' share links from the default 24 hours. The v2 docs describes this as affecting "system tokens" but no further explanation of system tokens is provided. The v3 docs refers simply to "tokens."

[edit: I believe one other thing this controls is the lifespan of password reset tokens.]

I'd like to increase the lifespan of draft entries' share links, but wonder what other consequences I should take into account before changing `defaultTokenDuration`. What all does it affect?

**Tags:** config, token


---

## 1 answers

### Answer by username_1 on 2018-11-17. Score: 1 | Accepted answer

Currently (as of Craft 3.0), it will affect entry and category share links. Some additional things might be using it in the upcoming 3.1 and plugins are free to use it for whatever they want.

For example, in Commerce 2, it is used for creating product preview share links.

> **Comments:**
> **username_2**: Thanks for clarifying. Has this changed significantly in 3.1+, Brad? It'd be helpful to understand the scope of `defaultTokenDuration` in the documentation.  

---

