If a negative thought pops up in your head more than once, tell someone about it. You don’t need to disclose your life story, but verbalising it can help you to put it in perspective.
If it’s really tough for you to speak to others, write it down. If you don’t have anyone to speak to, contact a charity like The Samaritans for a chat. Or slide in my DMs with a good bad joke.