In Matthew 24:24, we read the following: "For there shall arise false Christs, and false prophets, and shall shew great signs and wonders; insomuch that, if it were possible, they shall deceive the very elect."
This verse is referring to a particular time in history commonly called the great tribulation (Matthew 24:21). During the great tribulation, the church suffers persecution. In Matthew 24:9 we read, "Then shall they deliver you up to be afflicted, and shall kill you: and ye shall be hated of all nations for my name's sake." From this verse, we learn that some believers do not survive this time in history. In addition, in Matthew 24:12-13, we read, "12 And because iniquity shall abound, the love of many shall wax cold. 13 But he that shall endure unto the end, the same shall be saved." From these verses, we learn that some believers grow weary of doing good. In fact, the Letter to the Hebrews serves as a warning to Jewish believers about falling away from faith in Christ. If they were to fall away in the years leading up to the coming of Christ, they would face dire consequences, such as a potentially gruesome physical death during the great tribulation (Hebrews 10:25-31) and loss of rewards at the judgment seat of Christ (Hebrews 10:35-39). In order to be "saved" from these dire consequences, believers were exhorted to "endure to the end." This temporal salvation from physical death is further clarified in Matthew 24:22 where Jesus says, "And except those days should be shortened, there should no flesh be saved: but for the elect's sake those days shall be shortened." Matthew 24:22 and 24:24 tell us that it is "the elect" (a plural noun in the Greek) who "endure to the end" and avoid "being deceived." The elect have the honor of being "gathered together" by the angels at the end of the great tribulation when "the Son of man [comes] in the clouds of heaven with power and great glory" (Matthew 24:30-31).
What is important to note is that not all believers qualify as being "the elect." Some believers die as martyrs during the persecution (Matthew 24:9). Some undoubtedly die from natural causes (cf. 1 Corinthians 15:6). And some believers are actually destroyed during the great tribulation as temporal punishment for falling away or living ungodly (Hebrews 10, Revelation 2-3).
Matthew 24:24 does not teach that believers cannot be deceived or fall away from the faith. The only condition for receiving eternal life is to believe in Jesus for it. He did all the work for us when He died on the cross. As a result, salvation is a gift of God that does not depend on us "enduring to the end" and avoiding deceptions. "The elect" are a special group of believers. They probably correspond to, or are among, those called the "overcomers" in the Book of Revelation. Please see my article on Revelation 3:5 and Eternal Security regarding "the overcomers."