A few days ago my MacBook Pro (2018 model) started turning itself off whenever not plugged into a power point, despite having plenty of battery. After that, it wouldn't even start up fully before turning itself off - even when plugged in. I tried a few different things and some may work for you, but unfortunately not for me.
First, I tried resetting the power manager or SMC. Straight after starting up, I held down the left Control key, left Option key and right Shift key.
After that, I started up in Recovery mode and ran Disk Utility -> Disk First Aid. It encountered problems it could not fix - uh-oh! Time to wipe the internal drive and restore from backup.
I wiped the internal drive using Disk Utility - all the volumes listed for the internal drive and also the volume group. I reinstalled the operating system and let it run but it still wouldn't start up, either turning itself off or freezing.
I even tried creating a bootable installer on a thumb drive and running that. Same problem. At this point, I figured it could be a hardware problem.
I booked an appointment with Geeks2U and they were due to come today but the guy fell ill. No-one until a week later. I decided to book an appointment at a Mac repair shop in Perth and will go there tomorrow. I am writing this blog post from Dad's old MacBook, which doesn't have emoji, as you may have noticed.
Update: the Apple Centre on Hay Street ran a hardware diagnostic and only found that the battery needed replacing. I decided to simply use it plugged into power for now. I left it with them and in about an hour they managed to reinstall the operating system and get it working free of charge. The next day I got everything put back on it from a backup. All back to normal and I am using it now. 🥳
Wow Chris, you're really confident with computers! I would have immediately brought it somewhere because I know nothing!! If I have a computer question, I know who to come to!