Walter Hunt invented the safety pin substantially as we know it today. His improved pin design included a clasp that covered the point and kept it from opening, and a circular twist at the bend to act as a spring and hold it in place.
Hunt was born in upstate New York. After earning a degree in masonry, he worked as a farmer in the mill town of Lowville and devised more efficient machinery for local mills. He received his first patent in 1826. After moving to New York City, Hunt was granted patents for several devices, including a rope-making machine, fountain pen, and repeating rifle. In 1833, he invented the first workable sewing machine. It was well-received by the public, but Hunt never obtained a patent and was reluctant to take the financial risk to manufacture it.
The design for a better safety pin came to the inventor as he twisted an ordinary piece of wire while worrying about a $15 debt. Hunt sold his patent rights for the safety pin and repaid the debt with money left over, but realized only a tiny fraction of the wealth his invention generated.
Hunt continued to invent for the rest of his life. Although he sold the rights to most of his patents, letting others reap their financial benefits, he was well respected and recognized as a prolific innovator at the time of his death.