Puig said she has been building on a recent run of success, including a third-round showing at the French Open.
"Definitely pulling off some big career wins and not being afraid to close out matches, which was my problem at the beginning of the year," she said. "Finally just having the confidence to close them out."
Errani was runner-up at last year's French Open and had reached at least the semifinals of three of the last five Grand Slams. But on the slick grass at the All England club Monday, she had only 13 winners and was broken four times.
Puig squandered five match points before hitting a forehand winner past Errani to close the match. The Puerto Rican dropped her racket to the turf and covered her face in her hands.
Errani withdrew from last week's grass-court warmup at Eastbourne with a leg injury, but showed no signs of any physical problems during the match. Asked what went wrong, Errani said "a mix of everything."
"Always tough for me to play here on grass and she played very good," Errani said. "She served very good, did not make many mistakes and hit the ball strong. My big problem here is that I can't move how I want."
It's the third time a top-5 women's seeded player has lost in the first round at Wimbledon since 2001. The others were Martina Hingis in 2000 and Francesca Schiavone in 2010.
Monday's defeat marked another humbling Wimbledon exit for Errani.
Last year, the Italian went an entire set without winning a point in losing 6-0, 6-4 in the third round to Yaroslava Shvedova of Kazakhstan. Shvedova was the first player in a Grand Slam to achieve a "golden set" by winning 24 straight points.