File Corruption & Recovery

How to Recover Word Files with Changed Extensions After Malware Attack

Maira MehtabMaira Mehtab Oct 28, 2026 870 views

Question details

User's Word files have been renamed with unfamiliar extensions and cannot be opened, suggesting a possible ransomware or malware infection.

How to Recover Word Files with Changed Extensions After Malware Attack
Product
Microsoft Word
Device & OS
not provided
Scenario
Attempting to open or recover important documents after a suspected malware attack.
Observed behavior
Word files no longer open normally and display strange, random file extensions (e.g., .ycmnnjap) instead of the standard .docx format.
Before you start

Immediately disconnect your computer from the network and internet to prevent the potential ransomware from spreading to other devices or cloud storage drives.

Solution 1Recommended

Run a Security Scan and Restore from Backup

The safest and most reliable method to recover encrypted files is to remove the malware and restore clean versions from a secure backup.

Simply renaming the file extension back to .docx will not decrypt the contents if ransomware is involved. Attempting to force-open encrypted files may cause further data corruption.

Ensure your system is completely clean before restoring files to prevent your backups from being encrypted as well.

1
Disconnect from the network

Unplug ethernet cables and turn off Wi-Fi to isolate the infected computer from your local network and the internet.

2
Scan for malware

Run a full system scan using Windows Defender or a reputable third-party antivirus software to quarantine and remove the threat.

3
Check cloud backups

Log into OneDrive, Google Drive, or your preferred cloud storage from a different, secure device and check for clean versions of your documents.

4
Restore file history

If using Windows File History, connect your backup drive (only after the system is verified clean) and restore the affected document folders to a date prior to the infection.

Run a Security Scan and Restore from Backup
Do Not Pay the Ransom: Law enforcement and security experts strongly advise against paying ransoms, as it does not guarantee your files will be decrypted or returned.
Free Microsoft Office alternative

Switch to WPS Office to Protect Files with Cloud Backup

While ransomware requires specialized security tools to decrypt files, you can prevent future data loss by switching to WPS Office. It offers a lightweight, highly compatible alternative to Microsoft Office with seamless cloud backup features to keep your documents safe.

  1. 1. Download and Install: Download WPS Office Free from the official website and complete the quick installation process.
  2. 2. Sign in to WPS Cloud: Create a free account or sign in to activate 1GB of free cloud storage.
  3. 3. Enable Auto-Backup: Open your .docx files directly in WPS Writer and enable the Auto-Backup feature to protect against future data loss.
Fully compatible with Microsoft Word, Excel, and PowerPoint formats (.docx, .xlsx, .pptx).Built-in WPS Cloud provides automatic backups and file version history to easily recover from malware attacks.Free, lightweight, and fast-loading office suite designed for daily productivity.Familiar user interface ensuring zero learning curve for a seamless migration.
microsoft office alternative - wps office

Frequently Asked Questions

Can I fix the file by simply changing the extension back to .docx?

No. If a file has been encrypted by ransomware (e.g., changed to .ycmnnjap), simply changing the extension back to .docx will not decrypt the contents. The file will remain unreadable.

How do I identify if my files have been hit by ransomware?

Common signs of ransomware include randomly changed file extensions, a sudden inability to open your documents, and usually a ransom note (often a .txt or .html file) left on your desktop or inside the affected folders.

What should I do if I don't have a backup of the infected files?

If you have no backup, keep the encrypted files and check online security portals like 'No More Ransom' for free decryption tools released by security researchers. Do not delete the files, as a decryption tool may become available in the future.

Does restoring a previous version of Windows recover my files?

Sometimes. If System Restore or Windows File History was active before the infection, you might be able to right-click the folder and select 'Restore previous versions'. However, modern ransomware often deletes these local shadow copies to prevent easy recovery.