Surfboard leashes were introduced by Pat O'Neill in 1971. Originally called unaffectionately the "kook cord", they eventually won over the hearts and minds of almost all but the most crusty surfer. Most surfers use them most of the time, but it's not uncommon to see experienced surfers leave them in the car on small days. Some would argue that on huge days you might want to leave the leash off the surfboard so you it doesn't tie you down to a reef.
Remember that the leash is not an excuse to make zero effort to hang on your surfboard. Other surfers won't appreciate you casually flinging your surfboard at them with the oncoming sets. It's fairly easy to determine how much distance you need between surfers. Board length plus leash length plus 5ft or so for board movement and leash stretch=a big ass zone of danger. Also be prepared for your surfboard to rubber-band back at you...you might need to duck and cover. Always make an effort to hang on to that beast when other surfers are nearby, leash or no leash.
The correct length is usually slightly longer than your surfboard.
The thinner comp versions will produce less drag in the water, but don't slap them on your longboard. They are for smaller waves and lighter boards. Trust me, they will snap pretty easily if you push it. Most shortboarders that surf frequently will have them on hand, but thicker leashes are going to be more durable.
Leashes typically come in 6-10 feet in length and 5-10 mm thickness.
All leashes can, and will, break. This will probably happen on a bigger day when that leash is stressed to its limit. Its happened do me on the worst days far from shore, so never fully rely on it. Always be prepared to swim for it. It's a good idea to slap a newer leash on your board before tackling the bigger waves just to lower the chance of it snapping.