@sandey is right.
But be prepared to deal if the situation gets worse.
I know people who got caught watching porn by their wife and their relationship is in trouble. They had to make their wives sure that they still love her, feel sexually attracted to her to save their marriage.Your wife will think is she not beautiful for you now, are you not attracted to her now, do you not love her now.
So the best option is don’t tell her about your porn and masturbation addiction if you haven’t told her yet.
BUT WAIT A MINUTE. YOU CAN TELL HER THE OTHER PART OF THE TRUTH. THE PRESENT PART.
Just tell her that due to not having regular sex with her, you are getting horny and you don’t even want to betray her even by looking at other women. Tell her you are struggling with your urges and want her full support.
This method is more practical. I am 1000% sure(I hope), she will not react to it badly, but the opposite will happen.
She will see you as a loyal husband who loves her and does not want to betray her and needs her love. She will trust you even more since you are honest about your urges. In the end you will get more attention and love by your wife and you won’t feel the need to relapse.
(don’t be honest about PMO as most probably she will feel betrayed, if you relapse again then you should tell her about your addiction and ask her support and be ready to handle the situation)
Best of luck bro