Actually, all adult persons who I don’t mind being in the house unannounced without ringing have a key.
That's how I know it too. Those are the residents. Plus spare keys, each with parents in my case, given under the promise to never just show up without prior notification. Their spare keys, in turn, I have under the same promise.
The rest can ring the bell for completely spontaneous visits. That almost never happens. Beforehand a WhatsApp "hey, we’re just cycling in the area, are you there, would be at your place in 30 minutes?"
If it fits, then there’s coffee or beer or something. If not, I say so. If the message is not read in time, no one shows up either.
I find this approach very pleasant.