If you are using a cracked account then check this guide: How to allow cracked or non-premium players
If you have a Premium Account:
- Close ALL Minecraft related windows on your computer.
- Then open Minecraft again and try to join your server.
- If this does not work try restarting your computer.
If you recently changed your minecraft username:
- Close ALL Minecraft related windows on your computer.
- Then open the launcher and log out and log back in.
- Try to join the server.
If none of this helps you, contact support staff on discord or create a ticket. Want some help with tickets? Go here.