There really isn't anything special you can do to take care of it.
-Don't drop it.
-Don't spill liquids on it.
-Make sure the power pack or cord is in good condition, faulty power supply can cause problems.
-Keep it away from speakers or any other type of magnets.
-Keep it in a dry area, moisture will sometimes cause problems.
-Keep it away from extreme temperatures (hot & cold).
-Don't block air vents or put it in a small enclosure, it needs plenty of fresh air to keep from over heating.
-Keep vents clean of dust, hair and other particles- use can air to blow the vents out.
-If it is being used actively, add an external fan to help keep it cool.
The lifespan of hard drivers varies- I have some that last over 10 years but others that only lasted a few years or less.
Sometimes hard drivers will just go faulty no matter how well you take care of them.
Buy a well known brand with an extended warranty plan.
Enjoy!!