Rivets are placed on the parts of your jeans that are most likely to be ripped through wear and tear. Basically, they hold the fabric together so your jeans don't (awkwardly) fall apart.
It was a Levi Strauss blog post which decoded one of denim's most puzzling mysteries. According to the blog, "in 1871, Latvian immigrant Jacob Davis pioneered rivets while working as a tailor in Reno, Nevada.
"They were actually used on horse blankets before Davis came up with the idea to add them to clothing. He found they worked well for re-enforcing the stress point in men's work trousers - particularly the corners of the back pockets and the crotch, which often tore apart when exposed to heavy duty," the brand added.
Davis then took his idea to Levi Strauss, and together, they patented "improvement in fastening pocket-openings." Levi Strauss was the first company to manufacture riveted pants in the 1800s.