We know that you won't sit down to read an entire book on habits, so we will give you the summary right here.
A habit is basically a three-way cycle that involves a trigger, the action and a reward. You can apply this to every habit you have and it will make complete sense. Apparently, even eating is a habit because you are triggered by hunger or the sight or smell of food or a memory which prompts a craving.
You go by the food, then you consume it, which is the action, and if the food is nice you consume as much as you can until you’re satisfied, which is the reward. So, everything you kind of do subconsciously, but consciously over and over again can be a habit. It just depends on what it is you're doing and how often, and that's why there are bad or good habits.
Masturbation is one of the most popular habits from time immemorial. That is because the reward is most satisfying for mind and body in ways that other habits cannot reward. And with the digital world we live in now, you can imagine how many triggers you get every day. It's a tough world, isn't it?
Your brain can only fight your body as long as your mind is steadfast to a particular course. The slightest hint of indecision from the point of trigger to action is a sure tilt to action and ultimately reward, especially when it comes to any sexually related habits which have a high tendency of lingering long after contact.
With habits, the earlier you are able to ensure and utilize discipline, the easier it is to control your actions. You must administer a strong amount of restraint in the early stages of habit creation.
In cases where habits are far gone, the best way to stop them is to come from the point of the reward. Maybe someone walking in on you or it felt painful for no reason or you decided to pay for subscription to a porn sight and realized it was a stupid decision and a waste of money. The solution is to take that unpleasant feeling or memory and maximize the pain in your head, basically make it worse. This will in turn spoil the reward which will also stop the action, because really, it's all in your head. You just need to find a way to outsmart yourself.