Xavi has confirmed he was close to leaving the Camp Nou in the summer. Chris Brunskill/Getty Images

Xavi Hernandez has told Sport he had "the suitcase packed to head to New York" in the summer but now wants to see out his Barcelona contract.

Xavi, 34, was linked with a move to Major League Soccer clubs New York Red Bulls and New York City FC, with the latter reported to have agreed a deal for his services.

He has now confirmed that he had made the decision to leave Barca after being left out of the starting XI for the title-deciding 1-1 draw with Atletico Madrid at the end of last season.

"The season was over and I was disappointed to be on the bench for the game against Atletico Madrid and, with a new coach incoming with his own ideas and players, I felt that my time at the club was up," Xavi said in quotes translated by AS.

However, following Spain's early exit at the World Cup, he held telephone conversations with club president Josep Maria Bartomeu and new coach Luis Enrique, who both told him he "always had a place in the team."

He then made an appointment with Luis Enrique and sporting director Andoni Zubizarreta.

"They told me that I would be a useful player, that I had to show this, I'd play and we'd have a great year together," he said. "I had a day to reflect on this.

"I enjoy speaking with Luis Enrique, since that first phone call. He convinced me to stay. He was decisive. He changed my mind. I even had the suitcase packed to head to New York. Everything was agreed with [NYC FC CEO Ferran Soriano]."

Xavi now intends to see out his current contract, which ties him to the club until the summer of 2016, and feels it would have been a "huge" error leaving Barca.

He hopes Barca can win "at least" one major trophy this season as they look to bounce back from their disappointing campaign under Gerardo Martino.

"Barca can't have two consecutive seasons winning no major trophies," he said. "I believe that we will win one of the major tournaments this season."