Mica Craig, 47, said the reptile pounced as he was shopping at Wal-Mart in the north-western US state of Washington.
The man stamped on the serpent and was later treated at hospital with anti-venom, after his hand suffered serious swelling.
Wal-Mart apologized, and said it was investigating how the snake had entered the store in the city of Clarkston.
Kayla Whaling, a spokeswoman for the chain, said: “At this point, it appears to be an isolated incident.
“We are working with a pest management team, which is conducting a sweep of the property to ensure there is no additional rattlesnake activity.”
Another customer, Maria Geffre, told Reuters news agency the snake was at least 1 ft (30 cm) long with four rattles.
Mica Craig said the serpent attacked as he reached down to brush away what he thought was a stick from a bag of mulch.
The purchase was intended for his marijuana plants, which Mica Craig said he was licensed to grow for medical reasons.
Image source: Wikimedia Commons President-elect Donald Trump celebrated his election victory at the Ultimate Fighting…
Millions of voters across the US chose to return Donald Trump to the White House…
Donald Trump declares victory in the US election as he addresses jubilant supporters in Florida.…
Stocks around the world are rising as Donald Trump appears to be on the cusp…
Donald Trump has won Pennsylvania, North Carolina and Georgia and taken a lead over Kamala…
Quincy Jones, the celebrated musician and producer who worked with Michael Jackson, Frank Sinatra, Ray…