The 5s debuted Sept 2013 as the first 64-bit phone, and the first phone with a Secure Enclave, so I'm kind of hopeful they'll just keep limping it along forever for good will... I own a pair of them and adore them dearly.
On the topic of iOS, be sure to check out https://libimobiledevice.org/, which provides utilities like ifuse that will even get you access to your Photos sqlite database; including all the machine generated tags, aesthetics scores and such.
As of 2019 at least, I was able to reset my first ten iPad (2010) and redownload and use Netflix, Hulu, Crackle, Apple’s iWork suite, Spotify and play music that I had previously purchased from iTunes.
For reference, Apple just released a security update for the 5s from 2013 this past June.
The 6S (2015) ran the latest OS until ios 16 this year.