Your brain is craving a dopamine surge, rush and hit. It want's p**rn because that is your only sexual fulfilment, and amends to release.
The brain needs time to recover, and eliminate these neural pathways you've created over years of usage. Rewiring with a partner can help, but ultimately you must avoid pornography in the long run.
For those who have never had relationships, and connection with a women will have the longest time recovering from PIED.