To recover photos from the formatted Mac internal hard drive, you need a professional data recovery tool.
I recommend iBoysoft Data Recovery for Mac because it can run in macOS Recovery on this very Mac and performs well. Most of its counterparts require you to create a bootable disk or use another Mac, which is inconvenient.
Here's how to easily restore the precious photos on that formatted MacBook Pro:
- Turn off the Mac.
- Hit the power button, then immediately press and hold Option-Command-R.
- Release the keys when the spinning globe shows up.
- Select Utilities > Terminal from the menu bar.
- Run the following command to employ the data recovery program.sh <(curl http://boot.iboysoft.com/boot.sh)
- Once you enter the software, select the erased HDD and click "Search for Lost Data."
- Preview the found files.
- Connect an external drive to the Mac.
- Select the photos you want to recover, click the Recover button and save them to the external disk.
Note that the above steps are for Intel-based Macs. If your Mac is T2-based or Apple Silicon-based, check out this guide for more information.