It is possible for the needle in your compass to demagnetize over time if you store it near a strong magnet. However, the most likely need for a new compass is wear and tear from being crammed into a backpack, falling onto rocks, or tolerating extreme swings in temperature. If taken care of, a good compass could easily last a lifetime.