Eho! I'm writing this post from my cellphone, ask me why, why?
Because I lost my keys and I'm locked outside.
Then I started thinking about what should I do now, and I just remembered the times it already happened to me.
So, when it happens you can find few solutions to enter home again:
1- Jump the window: If you left open one window before locking yourself out, you can always jump and search for a second key inside or open the door from the inside. This will work only if you a copy of your key at home. If you live on the second or higher floor, you can always try to find some stairs or jump from your neighbor's window. But this may be a bit dangerous, do at your own risk.
2 - Do a hole on the door: If it's possible to open the door by turning down some kind of hanger from the inside, you can find a drilling machine and make a hole in the door, then introduce some kind of stick and turn the hanger down.
3 - Call the cat or the dog: Instead of making a hole on your door, try to call your pet, some are able to open doors too.
4 - Enter by the roof: If you have a roof on tiles, you can always climb there and try to move the roof tiles and enter, then just put them in place.
5 - Call a locksmith: I think it's the better solution, if you have your cellphone with you just call someone to help you, he will open the door, make a new copy of the key and safely put you back inside.
Try to get safer locks, even if they are more expensive it's a good investment. Safer lockers also would cost more to be unlocked by a professional, and a new copy of your key would cost more too. But you are more safe from someone who would come to your house, and unlock your door using professional material. Good locksmiths are like Schlüsseldienst Berlin.
In Germany you can really have a very nice service, you can find special lockers that only trustful locksmiths have the knowledge on open it, and they can only do in the presence of the key owner.
Always call trustful locksmiths, always have a number of a locksmith which is available 24/24h and 7/7 days, you never know when shit will happen.
And if you don't know the number of any locksmith working by the time you are locked out, just go to a friend's place, or a bar, and wait until working hours come.