Use a screwdriver to tighten the screws attaching the hinges to the door and the door frame.
How to fix a door hinge that keeps closing.
By bending the hinge you have increased the internal resistance within the hinge so it keeps the door from moving as easily as before.
If your door has only two hinges close.
If one is loose remove two or more screws and try driving in longer screws.
On the latch side a door is cut at a slight bevel to make it easier to close.
Work your way from the top of the door to the bottom.
The door should no longer move itself.
Adjust the hinge to have it align correctly and snugly with the door and frame.
Check to see if the hinges are aligned correctly before you take the hardware off the door completely.
If you have a really crooked frame and still need just a little more resistance remove another hinge pin and perform the same magic.
Open the door and check that the hinge pins are seated all the way within the hinge.
Remove the pin by placing a screwdriver under the middle hinge.
Place a large nail or small screwdriver on the bottom of the center hinge pin of your door.
Take a hammer and long nail and tap the pin gently from the highest hinge.
How to fix a door that swings shut.
If not align the hinge knuckles and tap the pins.
Tap it with a hammer forcing the nail out the top of the hinge.
If a door binds open it grasp the knob and lift up to see if a hinge is loose.