You need to change your relationship with food. You need to start viewing food as fuel, and not comfort. Food is not your therapist, nor is it an escape, nor is it instant happiness. Food is fuel for your body, to keep you working properly. When you change your mind, you can change your actions.
Focus on portion control. When you put food on your plate for dinner, make sure you understand that the food you have in front of you is all you will be getting. Portion everything out, then if you have leftovers, put them into tupperware and into your fridge or pantry. Out of sight, easier to put out of mind. Drink a lot of water during your meals and snacks and really pay attention to what you are eating. Feel yourself getting fuller. Enjoy the different tastes you are tasting during your meal. Don’t watch tv or sit on the computer and mindlessly eat. Actually focus on the food.
Then when you are done, you are done. Keep yourself busy. Go out for a walk. Do some cleaning or chores around the house. Listen to music or read a book. Put the excess food out of your mind. You do not need that extra servings. You are full and satisfied. You do not need to binge. You received the fuel you needed for your body, and now you are going to go out and use the body you just fueled. Invest in a lock if you need to and put it on your pantry or fridge after a certain time.
Don’t indulge until you feel you can indulge in moderation. Keep away from sugary/junk foods for a few weeks to detox and get it completely out of your system. Then when you’re ready, allow yourself two cookies. Put them on a plate and put the box far back away in the cupboard. Tell yourself you are having two cookies and that is it. You do not need the others. Two will suffice. And really enjoy the cookies, and allow yourself the indulgence.
Self-control is like a muscle. Over time as you exercise it more, it will get stronger. It will get easier. If you feel as though you have exhausted all efforts and you have no control, seek out professional help. Binge eating disorder is as real of a disease as anorexia and bulimia, so do not be afraid to ask for help. Sometimes there are things larger than us that we cannot gain control of and we need more help to get a handle on it.