On October 7, 2023, while serving at the Gaza border, Edan was captured by Hamas during a surprise attack. His release was facilitated by a temporary cessation of hostilities, described as a goodwill gesture by Hamas and part of ongoing discussions about a potential ceasefire, particularly pertinent with US President Donald Trump set to visit the region. President Trump expressed his joy for the Alexander family and emphasized the importance of continued efforts to secure freedom for the remaining 58 hostages, highlighting the tense atmosphere as the Israeli military intensifies its operations in Gaza.

Following his release, Edan was seen being handed over to Red Cross officials in Khan Younis, before being transferred to Israeli authorities, leading to a heartfelt reunion at an Israeli military base. His mother, Yael, communicated with him over the phone, expressing her pride and reassurance. Prime Minister Benjamin Netanyahu recognized the moment as both poignant and significant, thanking Trump for his intervention. The situation remains complex as tensions persist, with Israeli military plans underway to escalate operations in Gaza coupled with ongoing negotiations regarding hostages and humanitarian aid, amid dire warnings of a humanitarian crisis in the region.