# How to check k8s certificate expiration?

**URL:** https://forums.k8slens.dev/t/how-to-check-k8s-certificate-expiration/2324
**Category:** All about k0s
**Created:** [November 27, 2023, 3:51pm UTC](https://forums.k8slens.dev/t/how-to-check-k8s-certificate-expiration/2324 "2023-11-27T15:51:19Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![dioni.pinho](https://forums.k8slens.dev/letter_avatar_proxy/v4/letter/d/258eb7/32.png) [@dioni.pinho](https://forums.k8slens.dev/u/dioni.pinho)
#### Post date: [November 27, 2023, 3:51pm UTC](https://forums.k8slens.dev/t/how-to-check-k8s-certificate-expiration/2324/1 "2023-11-27T15:51:19Z")

</div>

Hey all, how do I check when k8s certificates in a k0s cluster will expire?  
I tried using kube admin, but I don’t know if it’s the best way.

---

<div class="post-metadata">

### Author: ![jnummelin](https://forums.k8slens.dev/letter_avatar_proxy/v4/letter/j/c5a1d2/32.png) [@jnummelin](https://forums.k8slens.dev/u/jnummelin)
#### Post date: [December 7, 2023, 11:33am UTC](https://forums.k8slens.dev/t/how-to-check-k8s-certificate-expiration/2324/2 "2023-12-07T11:33:35Z")

</div>

One way is with the standard openssl tooling:

```auto
openssl x509 -in /var/lib/k0s/pki/server.crt -text -noout

```

The serving certs are generated with 1 year validity, k0s will renew them at every restart (reboot, upgrade etc. cases)

---

<div class="post-metadata">

### Author: ![denis.abreu](https://forums.k8slens.dev/user_avatar/forums.k8slens.dev/denis.abreu/32/1291_2.png) [@denis.abreu](https://forums.k8slens.dev/u/denis.abreu)
#### Post date: [August 26, 2024, 2:55pm UTC](https://forums.k8slens.dev/t/how-to-check-k8s-certificate-expiration/2324/3 "2024-08-26T14:55:58Z")

</div>

Hi, @jnummelin

Can you explain or send me a link to a document where I can find out how k0s manages the cluster’s certificates?

Thanks in advance. 👍
