The clove hitch is for tying to pilings when there aren't any dock cleats. Its best feature is that it can be easily tied when there is strain on the line, as there might be when docking in strong winds. The first turn around the piling is usually enough to hold the boat, keeping everything in place while you finish tying the knot. This is essentially a temporary knot, and may slip if the direction and strain on it changes.
1. Take a turn around a piling. 2. Take a second turn, this time crossing up and over the standing part of the line and the first turn. Tuck the end under and through the crossing you just made. 3. Pull both ends to snug up the knot. For a more permanent knot add two and a half hitches around the standing part of the line.