When modifying the sonoff I had the misfortune of tuning the unit upside down without its case in order to do some soldering. Twice this caused me to put too much pressure on the gpio0 pin and caused it to break off. Sometime the inner switch contact plate would also come out. Re-placing the inner contact plate and the button with lid back on with a little pressure allowed it to sink loosely back into its original slots. Following this a sealant usually used for the house in long tubes similar to caulking was used. It’s rubbery that it’s forgiving if you press the button slightly off centre. Other things tried.
- Electrical tape: too soft
- Superglue: not good for the metal cap
- Hot glue: when dry became brittle and cracked
- Just pressure to reseat the button works only for a moment.