To be able to avoid from the hackers, we should avoid the following:
1st: Protect your GMAIL or EMAIL ACCOUNT
We all know we use GMAIL as our email provider for such accounts like blockchain then we can recover and approve login with email in some wallets, now when your email account was targeted and get compromised then say goodbye to your bitcoin.To secure your bitcoin wallet(ex: blockchain or other) go to your google account settings. and then turn on the 2FA(2nd factor authentication) here is the guide on how to do it: STEP BY STEP GUIDE
2nd: Use your own DEVICE or COMPUTER/PHONE
It's a very bad idea to use someones device(ex:from friend) to make a transaction in your bitcoin wallet why? because first you don't know what is the capability of that person regarding that matters and you don't know if that phone has a lot of malwares and spywares.So we cannot say that you are safe using someones device to make transactions.
3rd: Always backup you PK's or PRIVATE KEYS
This is the most important thing to remember for everyone using your ETH or BTC wallet without backing up your Private keys then you can't recover you wallet in case you forgot your wallet.PK's are very important but there are thing you should do first. Make sure you store your PK backup somewhere that you only know and not from your computer because there are some spyware that might inside of your computer that can steal that file so make sure you back it up print in a paper and hide it to the place where you only know.
4th: Don't open links from malicious emails
This method was called email phishing where an attacker will send the same email in thousands of random users once the victim will click the link in that email then his or her device was compromised to avoid this please do not click the links included in the email immediately please always have time to check who is the sender of that email and if that email is came from the site where it supposed to came from.
5th: Do not trust PUBLIC WIFI
It's quite good to have access with free wifi's but have you think this: IS THIS A SAFE NETWORK? without you knowing maybe some of the people connected to that same network may have idea and skill on how to sniff passwords and credentials this method was so called DNS SPOOFING or SNIFFING if you want to use public wifi then use it not just with your bitcoin transactions.
6th: Do not login on Suspicious links
This method is called PHISHING where an attacker will send you a link to login with your bitcoin wallet luring you with the legitimate site example is:
the real site is:
https://www.blockchain.info/the fake site is:
http://www.blockchain.ga/then once you login to the fake site then the hacker or attacker will have now your credentials. Please always check for the green lock on the url bar and the word HTTPS in the link.
Credits to: Edsnowangel
https://bitcointalksearch.org/topic/how-to-stop-hackers-to-hack-your-crypto-wallet-2978832