tdata Folder Theft (Telegram Session Hijacking)Stealing the tdata folder is one of the most dangerous methods hackers use to take over your Telegram account without needing an OTP code or your Two-Step Verification password. When the Telegram Desktop application runs on a computer, it creates a folder named tdata to store confidential login data (Session Tokens). If a hacker manages to copy this folder, they can open and access your account on their own computer immediately.

tdata Folder and Why is it Important?When you log into your Telegram account on a computer (Windows, macOS, or Linux), the application saves your authentication data and encryption keys in a specific directory:
Windows: C:\Users\[Username]\AppData\Roaming\Telegram Desktop\tdata
This folder acts like a "master key." So you don't have to repeatedly enter your phone number and OTP code every time you turn on your computer, Telegram uses the data inside tdata to verify your identity. If your computer gets infected with Info-stealer malware (such as RedLine, Raccoon, or Lumma Stealer), the malware will automatically copy the tdata folder and send it directly to the hacker.
tdata FolderAttackers cannot steal tdata remotely on their own unless they first trick you into downloading and running a malicious file on your computer:
Disguised Files Sent Directly via Telegram: Sending files with extensions like .exe, .scr, .bat, or compressed archives like .zip / .rar disguised as invoices, work documents, or photos.
Cracked or Fake Free Software: Downloading unlicensed video editing software, games, or Office tools (Cracked Software) from untrusted websites.
Malicious Links: Tricking you into clicking links that automatically download malware onto your machine.
To prevent your tdata folder from falling into the hands of hackers (or to ensure hackers cannot open it even if your computer gets infected), follow these steps:
Setting a Local Passcode doesn't just lock your Telegram screen; it encrypts the entire tdata folder using your passcode. Even if a hacker steals your tdata folder, they will not be able to use it because the data is locked and encrypted.
Open Telegram Desktop on your computer.
Go to Settings, then select Privacy and Security.
Find Local Passcode and click Turn On.
Set a strong passcode and configure a short Auto-lock timer (e.g., 1 minute or 5 minutes).
Whenever you step away from your computer, click the Lock icon at the top of the Telegram window to lock it immediately.
Although 2FA cannot directly block tdata theft, it prevents hackers from changing your password or deleting your account, and it protects against unauthorized logins via SMS codes.
Go to Settings -> Privacy and Security -> Two-Step Verification and set an additional password.
Frequently inspect whether any unfamiliar devices are connected to your account.
Go to Settings -> Devices (or Active Sessions).
If you see any unrecognized computer or phone, click on it and select Terminate immediately.
Disable Auto-Download: Go to Settings -> Advanced -> Automatic media download and turn off automatic downloads for Files.
Never Open Suspicious Files: Avoid opening .zip, .rar, or .exe files sent by strangers—or even by friends if sent without context (as your friend's account might already be hacked).
Keep Windows Defender or Antivirus Active: Never disable your antivirus software when installing programs.
tdata Was StolenIf you suspect your computer is infected with malware or notice unusual activity on your Telegram account, take these emergency steps immediately:
Use Your Smartphone Immediately: Open the Telegram app on your phone, go to Settings -> Devices, and tap Terminate All Other Sessions to kick out all computer connections (including the session stolen by the hacker).
Disconnect Your Computer from the Internet: Turn off Wi-Fi or unplug the network cable from the suspected computer.
Remove the Malware or Reinstall Windows: Run a trusted antivirus scanner (such as Malwarebytes or Windows Defender Offline Scan) or perform a clean reinstallation of your operating system (Reinstall Windows) to ensure the malware is completely wiped before logging into Telegram on that computer again.