To create an encrypted virtual drive in Windows 10 or 11 Pro, make a VHDX file in Disk Management (or in Settings on Windows 11), format it as a new drive, then right-click that drive in File Explorer and choose Turn on BitLocker with a password. You get one container file that mounts as its own drive letter and stays unreadable whenever it is locked. On Windows Home, where BitLocker is not available, an encryption app with a vault drive does the same job.
This guide walks through the built-in method step by step, explains how to open and lock the drive day to day, and covers the options for Home editions.
What an encrypted virtual drive is, and why it is handy
A virtual drive is a single file on your disk that Windows can attach and treat as a separate drive, such as V:. Inside it you have ordinary folders and files. When the virtual drive is encrypted, everything inside that file is scrambled until you unlock it with your password.
That gives you a few practical advantages over encrypting files one by one:
- Programs just work. Word, Excel, photo editors and accounting software open and save files on the drive like any other location.
- One password for a whole set of files. Unlock once in the morning, lock once when you finish.
- Easy to back up. Copy the locked container file and the backup is encrypted too.
- Names are hidden. When the drive is locked, nobody can see which files are inside, only that the container exists.
Method 1: A BitLocker-encrypted VHDX (Windows Pro, Enterprise, Education)
Step 1: Create the virtual hard disk
- Right-click Start and choose Disk Management.
- Open the Action menu and choose Create VHD.
- Click Browse and pick a location and name, for example
D:\Private\vault.vhdx. Avoid putting it inside a folder that syncs to the cloud while you set it up. - Enter a size. Choose more than you need today, such as 20 GB.
- Choose VHDX as the format and Dynamically expanding, so the file only takes the space actually used. Click OK.
On Windows 11 you can do the same from Settings → System → Storage → Advanced storage settings → Disks & volumes → Create VHD, which walks you through formatting as well.
Step 2: Initialize and format it
- In Disk Management, the new disk appears as Not Initialized. Right-click its label on the left and choose Initialize Disk, then pick GPT.
- Right-click the unallocated space and choose New Simple Volume.
- Accept the full size, pick a drive letter and format it as NTFS with a label such as "Vault".
The new drive now appears in File Explorer under This PC.
Step 3: Turn on BitLocker for the drive
- In File Explorer, right-click the new drive and choose Turn on BitLocker. On Windows 11 it may be under Show more options.
- Tick Use a password to unlock the drive and enter a long passphrase.
- Save the recovery key. Save it to a file on a different drive, print it, or save it to your Microsoft account. Do not save it inside the virtual drive.
- Choose Encrypt used disk space only, which is quick on a new, empty drive.
- Choose Compatible mode if you may attach the file on an older Windows 10 PC, otherwise New encryption mode.
- Click Start encrypting.
On the password screen, BitLocker may offer to unlock the drive automatically on this PC. Leave that off. Automatic unlock means anyone signed in to your account gets in without the password, which defeats much of the purpose.
Opening and locking the drive day to day
A VHDX does not reattach itself after a restart, so the routine is short but manual:
- Attach: double-click the
.vhdxfile in File Explorer. Windows mounts it and the drive appears, still locked. - Unlock: double-click the drive and enter your BitLocker password.
- Work: open and save files on the drive as normal.
- Lock: close the files you were using, then right-click the drive and choose Eject. The container detaches and is fully encrypted again.
Restarting or shutting down also detaches it. Simply signing out does not always, so make ejecting a habit. If you share the PC, our guide to auto-locking a folder when the computer is idle covers the risk of leaving things open.
Method 2: Windows Home and other options
Windows 10 and 11 Home can create and attach VHDX files, but Turn on BitLocker is not available for them. Device Encryption on Home protects the internal system drive only and has no option for a password-protected container. See BitLocker on Windows 11 Home for exactly what Home includes.
That leaves two practical routes:
- An open-source container encryption tool. Several exist. They are powerful but take some learning, and you need to keep track of the container, its settings and the tool itself.
- An encryption app with a vault drive. Document Key includes an encrypted vault that appears as its own drive letter when you unlock it. Files you save there are encrypted the moment they are saved, and the drive disappears when you lock it. It runs on Windows 10 and 11, including Home.
Document Key's vault also locks itself when you are idle, when the PC sleeps or when you sign out, which removes the "forgot to eject it" problem that the BitLocker method has.
How the approaches compare
| BitLocker VHDX | Document Key vault | |
|---|---|---|
| Windows editions | Pro, Enterprise, Education | Windows 10 and 11, including Home |
| Own drive letter when unlocked | Yes | Yes |
| Locks automatically when idle | No, eject manually or restart | Yes, also on sleep and sign-out |
| Recovery if password is forgotten | 48-digit BitLocker recovery key | Recovery key saved at setup |
| Setup steps | Several, in Disk Management and BitLocker | A few clicks |
Backing up an encrypted virtual drive
Always back up the container while it is locked. A locked VHDX or vault is encrypted at rest, so the backup copy is encrypted too and is safe to keep on an external drive or in cloud storage.
- Eject first. Copying a VHDX while it is attached and in use can give you an inconsistent copy.
- Expect large uploads. A cloud service sees one big file and may re-upload the whole thing after a small change. A smaller container, or a few containers by topic, keeps this manageable.
- Back up the recovery key separately. A backup you cannot unlock is no backup.
If you want individual encrypted files in a synced folder instead of one large container, our guide to encrypting files before uploading to the cloud compares the two approaches.
Common problems
| Problem | Fix |
|---|---|
| Create VHD is missing from the Action menu | Click an empty area of Disk Management first, then open Action again |
| Turn on BitLocker does not appear | The PC runs a Home edition, or the drive is not formatted yet |
| Drive letter disappears after restart | Normal: double-click the VHDX to attach it again |
| "The disk is in use" when ejecting | Close programs and File Explorer windows using files on the drive |
| Container runs out of space | Detach it, run diskpart, then select vdisk file="D:\Private\vault.vhdx" and expand vdisk maximum=30000 (size in MB); attach, unlock and use Extend Volume in Disk Management |
Is a virtual drive the right tool?
An encrypted virtual drive is ideal for a working set of sensitive files you open often: tax paperwork, client records, financial spreadsheets. It is less suited to sending files to other people, because anything you copy out of the drive leaves it decrypted. For that, encrypt the individual file or use an encrypted package. And whichever method you choose, the drive is only as safe as its password, so pick a long, unique one and store the recovery key away from the PC.
Frequently asked questions
What is an encrypted virtual drive?
It is a single encrypted file that Windows can mount as a separate drive letter. While unlocked you use it like any drive, and when locked the contents are unreadable.
Can Windows 11 Home create a BitLocker virtual drive?
No. Home can create and attach VHDX files, but turning on BitLocker for them needs Pro, Enterprise or Education.
Can I back up an encrypted virtual drive?
Yes. Back up the container file while it is locked. The backup stays encrypted, so it is safe to keep on an external drive or in cloud storage.
