Most i've done recently are 24 hour fasts. I do have trouble sleeping sometimes while fasting. I can't really afford that, nor can i afford to become very irritable as fasting can sometimes make me. I think fasting is effective though.That's simply wrong on fasting, at least within short windows. My fasts are usually 30-36 hours going from after dinner one night, skipping eating the next day and eating again the following morning.
The science shows it's the best way to burn almost pure fat and it's actually very muscle sparing due to huge pulses of GH that raise it to 600-700% of baseline within 24 hours. From a survival aspect this makes perfect sense as the body wants to give you energy short term that you need to go "find food" without causing a loss of muscle which will help you find food.
Compared to virtually every other method of losing weight that is at best 50% fat and 50% muscle, short term fasting is 90% fat loss. Literally the best you can do without using some crazy drug that can burn out your mitochondria and kill you. Forgot what that's called... it's super effective but super dangerous because the optimal dose and the kill you dose are very close together. Or possibly some sort of cryogenic/ice bath stuff that causes your body to burn calories to stay warm.
As a protective measure, just in case, I intake 10g of Perfect Amino BCAA's on fasting days which basically provide some protein building blocks with no calories.
I would recommend doing that as it will still allow you to fast but also provide some amino acids. It may not be necessary, but if it helps in any way, it's a bonus. I have not noticed any negative effects on muscle growth/muscle loss while fasting and I have done some form of it for many years now.
Some also recommend drinking electrolytes to ensure you aren't disrupting that balance and making it easier on your body once you stop fasting, but I have never done that. Might try it and see if it has any effect.
It's possible Peter Attia was doing multiple day fasts. I know at one point he mentioned once a month doing a 3 day fast.