Praise be to Allah.
I‘tikaaf means staying in the mosque to worship Allah, may He be glorified and exalted.
The purpose of i‘tikaaf is for the individual to devote his time to worshipping Allah, may He be exalted, far removed from everything that may distract him. Therefore the Messenger (blessings and peace of Allah be upon him) used to observe i‘tikaaf in a small tent inside the mosque, so that this place would be only for the person who was observing i‘tikaaf and he would not be distracted by other people in the mosque, as he could not see them and they could not see him.
This is what the person who is observing i‘tikaaf should be keen to do, but if he speaks briefly to some of the people, or someone comes to visit him and he talks to him, there is nothing wrong with that.
But this conversation should be in a low voice, so as not to distract any of those who are remembering Allah, may He be exalted, reading Qur’an or praying in the mosque.
And this talk should be brief and should not distract him from the purpose of i‘tikaaf.
Al-Bukhaari (2035) and Muslim (2175) narrated from ‘Ali ibn Husayn that Safiyyah – the wife of the Prophet (blessings and peace of Allah be upon him) – told him that she came to the Messenger of Allah (blessings and peace of Allah be upon him) to visit him when he was in i‘tikaaf in the mosque during the last ten days of Ramadan, and she spoke to him for a while, then she got up to leave, and the Prophet (blessings and peace of Allah be upon him) got up with her.
Ibn Daqeeq al-‘Eid (may Allah have mercy on him) said in al-Ihkaam (2/45):
This hadith indicates that it is permissible for a woman to visit the one who is in i‘tikaaf and it is permissible to talk to the one who is in i‘tikaaf. End quote.
Shaykh Ibn ‘Uthaymeen (may Allah have mercy on him) said:
The deeds of the one who is in i‘tikaaf may be divided into several categories: those that are permissible, those that are prescribed and encouraged, and those that are prohibited.
As for those that are prescribed, he should focus on worshipping Allah and seeking to draw closer to Him, because this is the essence and purpose of i‘tikaaf. Therefore it is limited to the mosques (and cannot be done elsewhere).
Another category is that which is prohibited, which refers to anything that is contrary to i‘tikaaf, such as if the person was to go outside of the mosque with no excuse, or to buy or sell, or to have intercourse with his wife, and other deeds that would cancel out i‘tikaaf because they are contrary to its purpose.
The third category is that which is permissible and allowed, such as talking to people, asking them how they are and other things that Allah, may He be exalted, has permitted to the one who is observing i‘tikaaf.
End quote from Majmoo‘ Fataawa wa Rasaa’il al-‘Uthaymeen (20/175-176)
He also said:
There is nothing wrong with him talking briefly to his companions who are with him in i‘tikaaf or who have come in to visit him.
End quote from Jalasaat Ramadaniyyah (18/15)
He also said:
I‘tikaaf: is what is meant thereby that some friends get together in a corner of the mosque to talk about unimportant matters and that in which there is no benefit, or is the purpose to devote oneself to worshipping Allah, may He be glorified and exalted? The latter is the purpose of it, so beware of wasting this precious time in talking to your friends and wasting time. But if you talk to them sometimes, there is nothing wrong with that, because the Prophet (blessings and peace of Allah be upon him) talked to his wife Safiyyah bint Huyayy (may Allah be pleased with her) at night, then he got up to walk her back to her house.
End quote from al-Liqa’ ash-Shahri (70/8)
Shaykh Ibn Baaz (may Allah have mercy on him) said:
With regard to talking in the mosque: if it is about worldly matters and is a conversation between brothers and friends about some of their worldly concerns, if it is brief then there is nothing wrong with it, in sha Allah, but if it goes on at length then it is makrooh. It is makrooh to take the mosques as places for talking about worldly matters, because they were built for the remembrance of Allah, reading Qur’an, offering the five daily prayers and other good deeds, such as offering supererogatory prayers, observing i‘tikaaf and holding study circles.
But with regard to taking them as places to chat about worldly matters, that is makrooh, but a little of that, if necessary, when greeting one’s brother with salaam when meeting him, and asking him how he and his children are, and so on, or talking about worldly matters, so long as that does not go on at length and is done briefly, there is nothing wrong with that.
End quote from Fataawa Noor ‘ala ad-Darb (2/706)
For more information, please see the answers to questions no. 4448, 49007 and 106538
And Allah knows best.