SIM cards are durable, but not indestructible. If the card has been scratched, or if moisture has gotten into the phone causing corrosion on the gold contacts, the card may be permanently damaged.
If you have access to a friend’s phone or a spare device, try inserting your SIM card into that phone. invalid sim means
Accumulations of dust, oil, and carbon buildup block the communication pins inside the tray slot. SIM cards are durable, but not indestructible
This is the most common cause. If your phone has been dropped, jostled, or subjected to temperature changes, the SIM card may have shifted slightly in its tray. Even a millimeter of movement can break the connection between the card’s gold contacts and the phone’s reader. Accumulations of dust, oil, and carbon buildup block
Seeing "Invalid SIM" is annoying, but it is rarely a sign that your phone is ruined. Most of the time, the SIM card has simply shifted in its slot or gotten dirty. By cleaning the card and reseating it in the tray, you can usually get back online within minutes. If that fails, a visit to your carrier for a fresh SIM card is the final solution.