When babies are born, their skull is made up of many different bones, and soft spots (officially called fontanelles) are the gaps where these bones haven't grown together yet. There are two main soft spots—anterior (on top of the head, and the main one people refer to as the soft spot) and posterior (on the back of the head, though you might not actually feel this one). You also might feel ridges, where bones are overlapping. These spots exist to allow your baby's head to mold during the birth process (did you notice your baby's head dramatically change shape during the first days of life?) and then continue to grow while remaining nice and round.
But don't let their name scare you (or the fact that the area pulses with baby's heartbeat), soft spots are actually very strong and protected by a sturdy membrane. You can't hurt baby's brain or any other parts of his or her head by touching them. In fact, when you shampoo, you need to wash and scrub the soft spot to remove flake buildup—otherwise you'll end up with cradle cap. Yes, soft spots might seem freaky, but there's really nothing to worry about—they serve an important function, and you don't have to treat them any different than the rest of the head. You may notice them until age 2 or 3, though some toddlers' will close earlier.