What Is a Trojan Horse Virus in Computing?
What Is a Trojan Horse Virus in Computing?
What is a Trojan horse virus? It is a type of malware that pretends to be something useful — a free game, a software update, a document, a cracked app — so that you install it yourself. Once it runs, it quietly does something else entirely: it can steal your passwords, open a backdoor for an attacker, spy on what you type, or download more malware. Unlike a computer virus, it does not copy itself into other files, and unlike a worm, it does not spread across networks on its own. It gets in because you let it in.
The name comes from the Greek story of the wooden horse the city of Troy willingly brought through its gates, soldiers hidden inside. The malware works the same way: the outside looks like a gift, and the danger is the part you cannot see. Understanding that one idea — deception, not self-replication — explains almost everything about how Trojans behave, how they spread, and how to stop them.
This guide explains what a Trojan horse virus is, how it differs from a virus and a worm, how it reaches your computer, the main types, the signs of infection, and what to do if you find one. The Antivirus & Malware category has the wider picture; this article is the practical one for this specific threat.
What is a Trojan horse virus? The definition in one paragraph
The US National Institute of Standards and Technology (NIST) defines a trojan as “a computer program that appears to have a useful function, but also has a hidden and potentially malicious function.” That is the whole definition, and every part of it matters: it appears useful, it hides its real function, and that function is potentially malicious. The phrase “Trojan horse virus” is technically a misnomer — a Trojan is not a virus, because a virus replicates — but it is the phrase most people search for, and security vendors use it themselves, so it is the phrase this guide uses too.
Trojan vs virus vs worm: the difference that matters
The three are often lumped together as “viruses,” but they spread and behave differently, and the difference changes what you do about them.
A virus is a file infector. It attaches itself to a legitimate program or file and copies itself into other files when the infected file runs. Its defining trait is self-replication: one infected file becomes many.
A worm is also self-replicating, but it does not need to attach to a file or wait for you to run anything. It spreads across networks on its own, exploiting vulnerabilities to move from machine to machine.
A Trojan does neither. It cannot copy itself and it cannot spread by itself. It is a single program that depends entirely on persuading someone to run it. That dependence is its weakness and its strength: it cannot reach you without your help, but because it arrives as something you chose to install, it often runs with your full permissions, past the defences that would stop a virus.
Put simply: a virus spreads itself, a worm spreads itself, and a Trojan tricks you into doing the spreading for it.
A short history
The term is older than the personal computer. The first time “trojan horse” was used to describe malicious code was in a 1974 US Air Force report analysing vulnerabilities in computer systems. Early Trojans in the late 1980s were mostly pranks or simple password stealers, delivered on floppy disks.
The modern Trojan arrived with the internet. Once malware could be downloaded, a Trojan could be hidden in anything: a fake codec, a “free” version of paid software, an email attachment that looked like an invoice. The first ransomware seen in the wild — the AIDS Trojan of 1989 — was delivered this way, demanding payment to unlock files. The pattern has not changed since; only the disguises have.
The most notorious example is Zeus, also known as Zbot, a banking Trojan that became infamous for stealing online banking credentials through keylogging and form grabbing — recording what victims typed into login pages and intercepting the data as it was submitted. Zeus showed what a Trojan is for: not destruction for its own sake, but quiet, profitable theft, running for months before anyone noticed.
How a Trojan gets onto your computer
A Trojan needs you to run it, so every delivery method is a form of persuasion.
Bundled software and fake downloads. The most common route. A free program — a video converter, a game cheat, a “system cleaner,” a cracked copy of paid software — carries the Trojan inside its installer. You wanted the program; the Trojan was the price, hidden in the bundle.
Phishing emails. An attachment that looks like an invoice, a shipping notice, a job application, or a document from a colleague. The file is usually a compressed archive or a document with macros, and opening it runs the payload. Business email compromise attacks use the same trick with more convincing lures.
Fake updates and scare pages. A website tells you your video player, browser, or Flash player is out of date and offers a download. A pop-up tells you your computer is infected and offers a free scan. The download is the Trojan; the scan is the infection.
Drive-by downloads and malvertising. Less common for Trojans than for other malware, but real: a compromised advertising network serves a malicious ad, and a vulnerable browser or plugin runs the payload without an explicit download. Keeping the browser and its plugins updated closes most of this route.
Removable media and shared drives. A Trojan on a USB stick can autorun or can sit disguised as a folder or a document. This is how Trojans still spread in offices and schools, where drives move between machines.
In every case the mechanism is the same: the file looks legitimate, and the user runs it with normal permissions. No exploit is required, which is why Trojans remain the most common type of malware detected by security vendors — and why user awareness is the main defence.
The main types of Trojans
Trojans are usually named for what they do once they are in, not for how they look. The common families:
Backdoor Trojan. Opens a hidden “backdoor” into your system, giving the attacker remote control. With a backdoor in place, the attacker can run commands, install software, read files, and use your machine as a relay. Remote access Trojans (RATs) are the best-known form.
Banking Trojan. Designed to steal financial data. It watches for banking sites, logs keystrokes, captures screenshots, and intercepts login credentials — Zeus is the classic example. Some also manipulate transactions in the browser, changing the destination account while the screen still shows the correct one.
Downloader Trojan. A small first-stage program whose only job is to download and install more malware. It is deliberately tiny and quiet, so it slips past detection, and then it fetches the real payload — ransomware, spyware, or a cryptominer — after it is safely inside.
Spy Trojan. Watches and records: keystrokes, screenshots, webcam and microphone access, browsing history. The notorious spyware FinFisher, also called FinSpy, was delivered as a Trojan. Spy Trojans are often sold commercially, which is why they are sometimes called “dual-use” — the same tool can be a legitimate monitoring product or a weapon, depending on who deploys it.
Ransomware Trojan. Delivers ransomware. The Trojan itself does not encrypt anything; it is the delivery vehicle that gets the encryption program onto the machine, often through a phishing attachment.
Botnet Trojan. Turns the infected computer into a node in a botnet — a network of compromised machines the attacker controls remotely. The machine is then used to send spam, launch denial-of-service attacks, or mine cryptocurrency, all without the owner’s knowledge.
Fake antivirus (scareware) Trojan. Pretends to be security software. It “finds” infections that do not exist and demands payment to remove them — and sometimes it is itself the infection it claims to detect.
Most real-world infections are combinations: a downloader that installs a banking Trojan, or a backdoor that later drops ransomware. The type names describe the job, and one Trojan can do several jobs.
What a Trojan actually does once it runs
The first thing most Trojans do is nothing visible. They run silently in the background, often with the same privileges as the user who installed them, and they avoid drawing attention — no pop-ups, no slowdowns at first, nothing to alert you.
Then, depending on the type, they steal, spy, or open the door. A banking Trojan waits for you to visit your bank. A spy Trojan records keystrokes and uploads the log. A backdoor Trojan phones home to a command-and-control server and waits for instructions. A downloader fetches the next stage. The damage is usually discovered weeks later, when money moves, accounts are locked, or a second piece of malware appears.
This quiet-first behaviour is the reason Trojans are dangerous: the infection and the harm are separated in time. By the time the harm is visible, the Trojan has had weeks to work.
The signs you have a Trojan
One sign proves little; several together are a diagnosis.
- Programs, toolbars, or files appeared that you do not remember installing.
- Your computer is slower, crashes, or freezes for no apparent reason.
- Your antivirus or firewall has been switched off and you did not switch it off.
- Pop-ups appear, your homepage changed, or searches redirect through an unfamiliar engine.
- Friends receive emails or messages from you that you did not send.
- Your internet usage spikes, or the hard drive works hard when you are doing nothing.
- Banking or account logins fail, or you see transactions you did not make.
If you see several of these at once, treat the machine as compromised: stop signing in to sensitive accounts from it, and move to removal.
How to remove a Trojan
Do not just delete the file you suspect. A Trojan often has more than one component, and deleting the visible part leaves the rest.
1. Disconnect from the internet. Pull the network cable or switch off Wi-Fi. This stops the Trojan sending data out and stops it downloading more malware. Do this first, before anything else.
2. Boot into Safe Mode. On Windows, hold Shift while clicking Restart, then choose Troubleshoot, Advanced options, Startup Settings, and Safe Mode with Networking off. In Safe Mode only essential programs load, which stops most Trojans from running and defending themselves.
3. Run a full scan with your antivirus. Use Windows Security or your installed antivirus and run a full scan, not a quick one. If your antivirus has been disabled by the Trojan, download a reputable on-demand scanner from another device and run it from a USB stick.
4. Remove what the scan finds, then scan again. Quarantine or delete the detections, restart, and run a second scan. A second clean scan is the confirmation; one scan is not.
5. Change your passwords — from a different device. If the Trojan was a banking Trojan or a keylogger, assume every password typed on that machine is compromised. Change them from a clean device, starting with email and banking, and turn on two-factor authentication.
6. Check for persistence. Look at startup programs, scheduled tasks, and browser extensions for anything unfamiliar. A Trojan that survives a scan usually survives because a scheduled task reinstalls it.
If the machine still misbehaves after two clean scans, the honest answer is a clean reinstall of the operating system. It is disruptive, but it is the only way to be certain a well-hidden Trojan is gone — and it is cheaper than the fraud a missed Trojan can cause.
How to avoid the next one
Trojans depend on your click, so the defences are mostly habits.
- Download software only from the vendor’s own site or a trusted store. Never from a download portal that wraps installers, and never a “free” copy of paid software.
- Treat unexpected email attachments with suspicion, especially archives and documents with macros — even from people you know, because their accounts can be compromised too.
- Read installer screens. Choose Custom installation and untick bundled offers.
- Keep the operating system, browser, and plugins updated, and leave real-time antivirus protection on.
- Use a standard user account for daily work, not an administrator account. A Trojan that runs as a standard user has far less it can do.
No protection is perfect, and Trojans are designed to look legitimate right up to the moment they are not. But the whole attack depends on one moment of trust — a
download, an attachment, an installer — and slowing down at that moment is the single
most effective defence there is.
Is a Trojan horse a virus?
Not technically. A virus copies itself into other files, while a Trojan is a standalone program that pretends to be useful so you will install it. Security vendors and users call it a “Trojan horse virus” anyway, because it is malware that infects your computer — but the mechanism is deception, not replication.
Can a Trojan spread to other computers by itself?
No. A Trojan cannot copy itself or move across a network on its own. It spreads only when a person copies the infected file, shares it, or runs it on another machine. That is what makes it different from a virus or a worm — and why it depends on social engineering.
Can a Trojan steal my passwords?
Yes, and that is one of its most common jobs. Banking Trojans and keyloggers record what you type, capture login pages, and send the credentials to the attacker. If you suspect a Trojan, change your passwords from a different, clean device and turn on two-factor authentication.
Will antivirus remove a Trojan?
Usually, yes — a full scan with an up-to-date antivirus will detect and quarantine most Trojans. But if the Trojan disabled your antivirus or installed a second component, you may need an on-demand scanner from another vendor, or a clean reinstall of the operating system, to be certain it is gone.
What is the most famous Trojan?
Zeus (also called Zbot), a banking Trojan that stole online banking credentials through keylogging and form grabbing. It showed how profitable a quiet Trojan can be: it ran for months on infected machines, stealing credentials without the owners noticing, and its code was later reused in many other malware families.
