One question that pops a lot is people who bought on inherited houses with a safe there. The combination was lost and the door was left open.
If the safe has a combination lock just like this one, you may find this helpfull:

So to start, look at the back of the door. There should be the lock. Remove the screws and the cover and you should get something like this:

On inserting the combination, basically what you are doing is rotating those wheels, aligning those cutted parts (gates) under the fence:
So, in order to do it, follow these steps (do it at your own risk, beware that locks may vary but the principle is the same for most of them):
1. Rotate the dial several times to the left untill you see ALL the wheels rotating (usually 3 turns).
2. Stop when the last wheel that was picked up (usually is the wheel that is closest to the dial, but may not be) is aligned under the fence (that part you saw on the last image).
3. Look at the number on the dial. On this case it's 33, the first number of the combination:
4. Rotate the dial to the right untill you pick just the other wheels but before picking the last one (usually 2 turns).
5. Stop when the second wheel is aligned under the fence and look at the number on the dial:
6. Do the same (to the left) with the last wheel untill you get this:
As you can see, all the wheels are aligned, and the fence can now drop into the gates.
7. Look at the number:
8. Rotate the dial to the right (on the image the arrows are pointing to the left, but remember you are rotating the dial from the front of the safe) until you align that cut on the wheel that is different from the others with the nose of the fence:
To get this:
If it drops, like on the image, everything is good. If it doesn't, you got one or more numbers wrong (usually just a little bit off, but wrong nonetheless). Repeat the process untill it drops. And don't forget to write down the numbers.
If the fence drops, test the combination a couple of times to see if it works, before closing the safe.
One very important thing:
Most locks have a piece called relocker that doesn't allow the bolt to retract when the cover is off. It's not important in this case, where you just need to get the combo. But in order to properly operate the lock, the cover must be in place. So be sure to test everything multiple times before closing the safe. And for the love of god, DO NOT CLOSE THE SAFE without installing the cover of the lock again.
If you did everything right, when you dial the combo and rotate to the right again, it will get a little click. Rotate more and BANG! Bolt retracted:
In this case, the combo was 33-5-62 (rotating left-right-left, and then right again untill it opens).
If you have any doubts, post them here, and we'll be glad to help

Hope I helped,
Good luck!