I have several smartphones that no longer work. I was going to rid of them one way or another, but it concerns me a bit that someone could recover information from those devices (photos, accounts, etc). Is it safe to dispose them?

I can’t delete anything since the phones don’t work. I can’t just remove the “hard drive” can I?