It is to prevent terrorists infiltrating, including Hamas terrorists. You have heard of Hamas suicide bombers etc haven't you? What their aims are?Feel free to read their charter. WB is under military occupation Gaza is run totally by Hamas within its borders.
26-year-old sustains serious injuries in Tel Aviv stabbing (Haaretz)
from the article: IDF order will enable mass deportation from West Bank