While setting up a new drive I deleted the wrong partition in Disk Management. It shows as unallocated space now. Is my data gone?
Deleting a partition removes the entry in the partition table, but the data usually stays in place until something overwrites it. Do not create a new partition or format that space.
TestDisk is a free tool that can find and restore lost partitions.
1. Download TestDisk from its official site and run it from a different drive.
2. Select the disk, choose the partition table type (usually GPT or Intel/PC) and select Analyse, then Quick Search.
3. If it lists your partition, press P to see the files and check they are right.
4. Choose Write to save the restored partition table and restart.
If TestDisk can not find it, a data recovery program that scans unallocated space can read the files without the partition. Always save the recovered data to another drive.
TestDisk found the partition and restored it. All files are back. Thanks!