JERUSALEM — After one and a half years living in dire conditions under the Islamic State in Syria and Iraq, including near-starvation, zero medical care and no access to education, an Israeli Arab family returned home to Israel last month, Israel's security agency Shin Bet said Thursday.

According to information released by Shin Bet, the couple, from the Israeli Arab city of Sakhnin, arrived in Raqqa, Syria, with their three children, ages 8, 6 and 3, in June 2015. They returned to Israel after the father, identified as Wissam Zbeidat, was wounded fighting for the Islamic State, and his wife and children were forced to live without electricity and running water.

The couple also told Israeli investigators that they had come across some “very disturbing” video footage, which “affected them deeply” and propelled them to leave, Shin Bet said.

Zbeidat, 41, and his wife, Sabrine, 30, were indicted Thursday by an Israeli court for traveling to an enemy country and joining the terrorist group, also known as ISIS. They both face jail time if convicted. The children were taken into the care of local welfare services.

According to Israeli media reports, the couple are accused of contacting a foreign agent, illegal exit, membership in an illegal organization, forbidden military training, and performing work and providing services to an unlawful association. Israel's Channel 2 news outlet said the couple admitted to the charges. “I decided to return to Israel on my own, but that does not mean I regret what I did,” Channel 2 reported Zbeidat as saying.

There have been reports that as many as 30,000 foreigners from more than 100 countries, including families, have flocked to Syria and Iraq to join the ranks of the Islamic State.

According to Shin Bet, the Zbeidat family left Israel on June 16 last year to visit relatives in Romania. They then traveled to Turkey where, via Facebook, they connected with another Israeli national who had joined the Islamic State in 2013. With the help of smugglers, the family then crossed the border into Syria.

Upon their arrival, their Israeli passports were taken. Initially they were taken to Raqqa, where Zbeidat was separated from his family and sent to Iraq. In Iraq, he studied Islamic State ideology and was later given military training, Shin Bet said. This included instruction in how to use rifles, machine guns and rocket-propelled grenade launchers.

After completing his training, Zbeidat was responsible for maintaining Islamic State facilities near the combat zone and later took part in raids on Iraqi army positions. During one of the raids, he was wounded and taken to hospital in the Iraqi city of Mosul. His family joined him there.

It is in Mosul that the family reveals some of the more harrowing details about life under the Islamic State. According to the Shin Bet statement, the family lived in a crowded house with no running water or electricity. The conditions were unsanitary and they had no access to medical care or basic medication. The couple also told Israeli investigators that their children were not allowed to attend school and were exposed to some infectious diseases.

The family told of other difficulties of life under the rule of the Islamic State, including discriminatory laws against women and cruel forms of punishment, such as amputation of limbs, flogging and public beheadings. They said a “morality police” enforced the dress code for women and measured the length of men’s beards. And they confirmed the claims of human slavery faced by members of the Yazidi minority, including using them for housework and sexual purposes.

The Islamic State is facing a major military offensive from Iraqi army forces and Kurdish fighters to drive them from the area. Earlier this year, Mosul also experienced heavy bombing. It was this incident, which left many casualties, that convinced the Zbeidat family that they should return home to Israel, Shin Bet said.

The family turned to relatives, asking them to pay thousands of dollars to border smugglers for them to reach Turkey. Shin Bet said the family attempted several times to cross the border, including walking through mountainous terrain and facing adverse weather with inadequate food and water.

At one point, said Shin Bet, they had to drug one of their daughters so that she would not give away their location. Several times they came under fire from both the Turkish military and from Islamic State fighters.

Upon reaching Turkey, the couple were arrested by authorities and placed in a detention camp. They were then released last month and returned to Israel. The family was arrested by Israeli police upon arrival at Tel Aviv’s Ben Gurion Airport.