Magnets lose their properties if they are heated, hammered or dropped from some height. Also, magnets become weak if they are not stored properly.
Ways to keep magnets safe:
1. They should be kept in pairs with their unlike poles on the same side.
2. For horseshoe magnet, one should keep a piece of iron across the poles.
3. Take care to protect the magnet against mechanical shock. Some magnets are brittle. They will crack or break if they fall on a hard surface or bang against metal or another magnet. Do not strike them with a hammer.