My iPhone is stuck in recovery mode

My iPhone is stuck in recovery mode and when I restore from my Mac or PC, it says "The iPhone 'iPhone' could not be restored. An unknown error occurred (4013)."

I used the iMyFone Fixppo app and it still won't work. When I try exiting, the phone is stuck in a boot loop and the screens turns red for a second.

crwdns2934089:0crwdne2934089:0 crwdns2934093:0crwdne2934093:0

crwdns2934109:0crwdne2934109:0

crwdns2889612:0crwdne2889612:0 0

crwdns2944067:02crwdne2944067:0:

Have you tried a different USB cable and USB port on your computer?

crwdns2934271:0crwdnd2934271:0crwdne2934271:0

4013 could be a nand issue

crwdns2934271:0crwdnd2934271:0crwdne2934271:0

crwdns2934285:0crwdne2934285:0