Your honest cry for forgiveness and healing has been heard, and it is right and good to bring this struggle into the light before God.
Scripture assures us that if we confess our sins, God is faithful and just to forgive us through Jesus Christ and to cleanse us from all unrighteousness. There is no sin beyond His mercy when we turn to Him with a sincere heart, and He receives that confession not to condemn but to heal, to correct and to restore. Forgiveness is a gift He delights to give, and with it He also trains our souls in gentleness and gives us strength to walk in a new way.
Pornography works against the purpose for which God made us. He gave us eyes and ears and mouths so that every part of us might serve Him, that we might speak His words, do His deeds, and offer thanksgiving with a pure conscience. When we turn those members toward what is unclean, we defile the very temple where He desires to dwell. For that reason God calls us to come out and be separate and to touch no unclean thing, so that He may receive us and make us whole. This is not only about turning away from something harmful, but about turning toward something better, becoming an example in purity, in speech, in conduct and in faith.
Healing often comes as a process. God deals with us not primarily with vengeance but with admonition and correction, to make the present struggle light in view of His greater mercy. Bring this daily to Him in prayer, asking not only for pardon for what has been done but for a purified conscience and a renewed mind. Fill what you once fed with darkness with what gives light, meditate on Scripture, let your mouth be exercised in spiritual words and hymns and thanksgiving, and your eye will become more piercing to see what is good.
It also helps to walk this out practically and not alone. Consider putting wise boundaries in place for your devices, bringing a trusted pastor or mature believer into your confidence for accountability, and filling idle moments with prayer, work, fellowship and service. When temptation comes, remember who dwells in you and turn quickly to Christ for help.
Let us pray together. Lord Jesus, thank You for Your cross that makes forgiveness possible. Forgive and cleanse this heart that has sought what is impure. Heal the wounds that have driven this habit, renew the mind, and make eyes and heart pure again. Give strength to turn from every unclean thing and grace to walk in purity day by day. Restore joy, self control and a clear conscience, and draw this life ever closer to You. Amen.
You are not alone in this fight. Keep seeking Him, keep confessing quickly when you fall, and keep trusting that His grace is at work to both forgive and to make you new.