How to create lease
Guide to creating a lease in etcd
lease to write with TTL:

etcdctl --endpoints=$ENDPOINTS lease grant 300
# lease 2be7547fbc6a5afa granted with TTL(300s)
etcdctl --endpoints=$ENDPOINTS put sample value --lease=2be7547fbc6a5afa
etcdctl --endpoints=$ENDPOINTS get sample
etcdctl --endpoints=$ENDPOINTS lease keep-alive 2be7547fbc6a5afa
etcdctl --endpoints=$ENDPOINTS lease revoke 2be7547fbc6a5afa
# or after 300 seconds
etcdctl --endpoints=$ENDPOINTS get sample
Last modified September 8, 2026 · refactor(docs): move component documentation under /docs (f643529)
Adapted from etcd v3.7 documentation (v3.7, commit 8245979), Copyright 2013-present etcd Authors, under CC BY 4.0. See attribution and change history.