I feel deep down in my heart that it's unlikely a magnet on the end of a hammer is the most efficient place for holding your nails. I can see, even with a strong magnet, the nails coming off when swinging hard, there is a lot of force on that end of the hammer. Your magnet would have to be really strong to effectively keep the nails in place.