Gibson revealed that he had spoken to De Villiers the day before last week's announcement by the star batsman but had been unable to convince him to change his mind.
"We had a conversation," said Gibson, who was briefing journalists ahead of the South African squad getting together to undergo their annual fitness and medical assessments.
"He called me the morning before he made the announcement," said Gibson. "We had a long conversation around whether he was making the right decision. He reckons he is. He has spoken to the people in his close circle."
Gibson said De Villiers' decision had been a shock to him. "He is one of the best players in the world. He could have made a huge difference in the World Cup and he knows that... he's chosen to walk away from the game at this time and it is what it is."
Gibson said the World Cup in England and Wales in June 2019 was still a year away. "We'll have to alter our plans obviously but it gives us enough time to do that."
De Villiers, 34, announced his retirement last Wednesday, saying he was "tired" after a 14-year international career during which he was hailed as one of the best players in the game. He said it had been a tough decision but that "I would like to retire while still playing decent cricket".
"It's disappointing for the country and world cricket that AB de Villiers isn't playing cricket anymore," said Gibson.