Tutorials/Shelter defense

Non-explosive resistant houses
It is HIGHLY suggested to use an explosion resistant house, or at least the floors in most danger of creeper attacks.

If you don't have explosive resistant blocks, make a moat, a lake, or a trap. To make a moat you can dig a 2 wide and 3 deep row that stretches along the perimeter of your house. Depending on how deep your moat is, as well as the availability of water (which should be available), sometimes it is not a good idea to fill your moat with water. Mobs can swim, making your work useless. You could also fill your moat with Lava, but lava is a bit expensive (due to availability and you cannot make an infinite lava source) and you will lose all mob droppings in the lava. It can also be dangerous for yourself, if you somehow fall in.

Alternatively, make a fence with iron bars; it defends the house and catches the explosion.

Safe Entrance
This opening will allow players to walk in, but not Zombies, Skeletons, and Creepers. However, Skeletons will still be able to shoot arrows through, and Creepers will still be able to explode when looking at you. It is therefore advised to combine this opening design with Vines hanging down the entrance, so that mobs won't be able to notice you, and Skeleton Arrows will be deflected. However, Arrows shot by the player will be able to pass through.

Explosive resistant houses
Explosive resistant houses are fairly easy to build, and aren't extremely expensive. However, they can be time consuming, depending on the materials used. Stone or Cobblestone is an easy, cheap way to build a home, but it can be destroyed by an explosion close by. A home made out of Bricks is as effective as cobblestone against explosions, but is expensive and very time consuming. Clay and a Furnace are required to make bricks, but you must have a good supply of Clay. The choice between using brick and cobblestone is solely aesthetic. Obsidian is another blast-resistant block, but is extremely expensive and hard to modify your house once built. Explosive resistant houses can be pointless if your house is small and you have a good supply of light for the area. You can also use End Stone, the most explosion resistant block after Obsidian and Bedrock, but to do this, you must have reached the End and defeated the Enderdragon.

Other Tips
You should have many windows, so as to be aware of any Mobs around. Light your houses and surrounding area well! It is suggested to have an automatic door and protect the surrounding area with a minefield, trap(s), or some sort of defense.

Try making multiple panic rooms/bunkers, preferably for different situations(i.e. creeper in front of your house, skeleton stalking you etc.). Another good idea is to make a emergency exit this is a deep hole with water at the bottom and some supplies, only use this if its an emergency.

Another, kind of hard idea, is make a way to get behind, under, or above a hostile mob around your house. This could include a tunnel, or, if you're epic, a water slide or roller coaster.

Try putting dispenser filled with arrows in front of your door(s). Creeper in front of your house? No prob! Hit a button! See how it works?

Security
It can come in handy if you have some security systems up. Here are some ideas:

• Alarm, to make an alarm you will need: Place pressure plate(s) around an area you would like to protect, or your entrance(s) try to keep them separated as much as possible (optional). Then attach the note block(s) to the pressure plate(s) with redstone wire. From now on, whenever a mob or a player walks on a pressure plate(s) the note blocks will generate a sound notifying you. If you mine a lot, put a note block(s) in your mine or along a rail road.
 * At least 1 pressure plate
 * Lots of redstone
 * At least 1 note block

• A self destruct system might be useful, to prevent others in SMP from stealing your belongs. For this to work, the TNT has to be concealed in a wall, and there should be redstone (that is concealed) attached to a button to activate the TNT. It is also recommended that you have a blast-proof room where you store/hide in before you activate the self destruct. The button should also be in this room.

• If you have a lot of iron ingots and pumpkins, then you can make the perfect defense. Iron Golems have 50 hearts and can kill most mobs in 1-2 hits. Make sure to keep them near your house though; as they may wander away. To prevent this, put the iron golems inside of a trench surrounding your house. The trench should be 2 wide and at least 4 deep, otherwise the golems will fling mobs back out of the trench.

You could try dispensers to defend your home entrance but you would need lots of arrows and string. Another idea is to push the mob or player in a moat to it a pressure plate, activating a dispenser. It works better with multiple dispensers, all with redstone repeater.

Another idea is to tame quite a few Ocelots and tell them to sit outside your house and other areas.

Golem Defense
To prevent any mobs getting near you, you can put some towers with snow golems behind a hole with lava, the snow golems will throw snowballs at the mobs and they will fall into the lava. This will NOT work with skeletons because they don't need to be near in order to attack. To keep quite a few mobs away at one time, create at least 5 Iron Golems outside your house, entrance(s), or other areas.

To have a high level of automatic protection, combine Iron Golems and Snow Golems.

For high, semi manual protect, use Iron Golems, Snow Golems, Wolfs, and traps.

Note:
 * Snow golems will die in rain so be sure to make a roof.

Wall Defense
You can add a 3 block tall wall with slabs on the other side You can also add murder holes to kill mobs. You can also build a wall of any length one and a half blocks tall for protection against all mobs but spiders. You will also be able to shoot mobs with a bow and arrow in first person mode, as the player is slightly taller than the wall. If you put a roof over you and/or your wall you will also be protected from spiders. You can use this to build a bunker. This is good for SMP for a fort or base. This Idea was originally thought of by a user named "markpwns1"