One should take all precautionary measures to save oneself from hackers. You should use a PC with good antivirus so that it can keep away all the malware, use safe browsers, always double check the website you visit especially websites like myetherwallet, etc., so that you don't land up putting your private key on the fake website, using offline wallet or physical wallet is another good idea to keep your funds safe.