Any malicious software
Examples of malware
A virus copies itself but it needs contact to spread. Most viruses come through emails and hack your email and eventually accounts connected to that email. A trojan horse seems legit but allows access to someone else. Spyware secretly obtains personal information. To avoid malware install an antivirus software, use common sense and use a fire wall.