Creating and formatting a hard disk partition is the process of dividing a physical drive into separate logical sections and preparing one of those sections with a file system so your operating system can store files on it. You do this with built-in tools like Windows Disk Management, macOS Disk Utility, or Linux fdisk/parted, and the result is a drive letter (like C: or D:) or a mount point that you can use for storage. This article explains the steps, the choices you need to make, and the common pitfalls so you can partition a disk safely.
What Is a Partition and Why Create One?
A partition is a logically defined region of a physical disk. The disk itself is just a flat sequence of bytes; the partition table (GPT or MBR) at the start of the disk tells the operating system where each partition begins and ends. Creating a partition does not erase data on other partitions, but it does require free space on the disk—either unallocated space or space carved out of an existing partition.
People create partitions for several reasons:
- Dual-booting two operating systems (e.g., Windows and Linux) on one machine.
- Separating system files from personal data so that reinstalling the OS does not wipe your documents.
- Organizing large drives into smaller, more manageable volumes (e.g., one for games, one for media).
- Using multiple file systems for compatibility with different devices or for specific features like compression or encryption.
Without partitions, an entire disk would be a single volume, which is fine for many users but less flexible for the above scenarios.
Before You Start: Backup and Understand the Risks
The single most important rule is to back up any data you care about before changing partitions. While creating a new partition in free space is low-risk, resizing, deleting, or formatting an existing partition will destroy the data on it. Even with careful steps, power loss or a software bug can corrupt the partition table.
Also check whether your disk uses GPT (GUID Partition Table) or MBR (Master Boot Record). Modern computers with UEFI firmware typically use GPT, which supports more than four primary partitions and disks larger than 2 TB. Older BIOS systems use MBR, which is limited to four primary partitions (or three primary plus an extended partition) and a maximum of 2 TB per disk. You can check this in Windows Disk Management (right-click the disk and choose Properties → Volumes) or with parted on Linux.
Step-by-Step: Create and Format a Partition in Windows
Windows provides two built-in tools: Disk Management (graphical) and DiskPart (command line). Here is the graphical method:
- Press Win + X and select Disk Management.
- Find the disk that has unallocated space. If you have no unallocated space, you can shrink an existing volume by right-clicking it and choosing Shrink Volume.
- Right-click the unallocated space and choose New Simple Volume.
- In the wizard, specify the size in MB (1 GB = 1024 MB).
- Assign a drive letter (e.g., D:) or choose to mount it to an empty NTFS folder.
- Choose a file system: NTFS for Windows system and programs, exFAT for external drives that need to work with Macs and game consoles, or FAT32 for maximum compatibility but with a 4 GB file size limit.
- Set the allocation unit size to Default unless you have a specific reason not to.
- Give the volume a label (e.g., “Data”) and check Perform a quick format.
- Click Finish. The partition is created and formatted.
If you need to delete a partition to free up space, right-click the volume and choose Delete Volume. This erases all data on that partition—make sure you have backups.
Step-by-Step: Create and Format a Partition on macOS
macOS uses Disk Utility for partition management. The process is slightly different because macOS uses a container structure (APFS) that manages volumes within a container.
- Open Disk Utility (in /Applications/Utilities).
- Select the physical disk (not the volume) in the sidebar and click Partition.
- Click the + button to add a partition. You can drag the divider to adjust the size, or type a size in the field.
- Choose a format: APFS (for modern macOS), Mac OS Extended (Journaled) (for older macOS or Time Machine), exFAT (for cross-platform), or MS-DOS (FAT) for FAT32.
- Click Apply and confirm. Disk Utility will create the partition and format it.
If you need to delete a partition, select it and click the – button. This removes the partition and merges the space back into the container.
Step-by-Step: Create and Format a Partition on Linux
Linux offers several tools; the most common are fdisk (for MBR) and parted or gdisk (for GPT). Here is a typical sequence using fdisk on a disk like /dev/sdb:
- Open a terminal and run
sudo fdisk /dev/sdb(replacesdbwith your disk). - Type
nto create a new partition, choose partition number (default 1), and specify the first and last sectors (or size with+10Gfor 10 GB). - Type
tto change the partition type if needed (e.g.,83for Linux,82for swap). - Type
wto write the partition table to disk. - Format the partition with a file system:
sudo mkfs.ext4 /dev/sdb1(ormkfs.xfs,mkfs.vfat, etc.). - Mount it:
sudo mount /dev/sdb1 /mnt/data. To make it permanent, add an entry to/etc/fstab.
For a GUI alternative, GParted is a popular tool that works on most Linux distributions. It provides a point-and-click interface for creating, resizing, and formatting partitions.
How to Choose the Right File System
The file system determines how the OS stores and retrieves files. Choosing the wrong one can cause compatibility issues or limit file sizes.
- NTFS (Windows): Supports large files, permissions, encryption, and journaling. Best for Windows system drives and internal data drives.
- APFS (macOS): Optimized for SSDs, supports snapshots and encryption. Best for macOS boot drives.
- exFAT: Lightweight, supports large files, and is readable/writable by Windows, macOS, and Linux (with exfat-utils). Best for USB flash drives and external hard drives shared between OSes.
- FAT32: Old but universally compatible. Max file size is 4 GB, so not suitable for HD videos or large disk images.
- ext4 (Linux): Default for most Linux distributions. Supports large files and journaling. Not natively readable by Windows without third-party drivers.
For a dual-boot data partition, exFAT is often the best compromise. For a Linux-only data drive, ext4 is a solid choice.
Common Problems and How to Fix Them
- “The operation is not supported” in Disk Management: This often happens when you try to shrink a volume beyond a point where system files are located. Defragment the drive first (on HDDs) or use a third-party tool like GParted from a live USB.
- Cannot create more than 4 primary partitions on MBR: Convert the disk to GPT (requires wiping the disk) or use an extended partition. On a data disk, you can convert MBR to GPT without data loss using
gdiskon Linux, but Windows does not offer a built-in non-destructive conversion. - Drive letter missing after formatting: In Disk Management, right-click the volume and choose Change Drive Letter and Paths to assign one.
- Partition not visible in Windows after creating on Linux: The partition may be formatted with ext4 or another file system Windows cannot read. Format it as NTFS or exFAT if you need cross-platform access.
- “Disk is write-protected”: This is usually a hardware switch on USB drives or a read-only attribute on the disk. Check the physical switch or run
diskpartand typeattributes disk clear readonly.
Frequently Asked Questions
Does formatting a partition erase all data on it?
Yes, formatting a partition removes the file system index and marks all space as available, so the existing data is no longer accessible. In most cases, the data is not physically overwritten, but it is effectively gone for normal use. Always back up before formatting.
Can I create a partition without losing data on the disk?
Yes, if you have unallocated space on the disk. If the disk is full, you can shrink an existing partition (if the file system supports it) to create free space. Windows and macOS both offer shrink functions, but they may not be able to shrink as much as you want due to immovable files. Third-party tools like GParted can often shrink more, but always back up first.
What is the difference between a partition and a volume?
A partition is a physical section of the disk defined by the partition table. A volume is a logical storage unit that the operating system sees. On a basic disk, a partition and a volume are essentially the same. On dynamic disks or with LVM on Linux, a volume can span multiple partitions or disks.
Should I use GPT or MBR for a new disk?
If your computer uses UEFI (most PCs from the last decade), use GPT. It supports disks larger than 2 TB and up to 128 partitions. MBR is only needed for very old BIOS-based systems or for compatibility with some old external devices. You can check your firmware type in System Information on Windows or by running efibootmgr on Linux.
Can I resize a partition after I have created it?
Yes, you can extend or shrink a partition if the file system supports it. Windows Disk Management can extend a volume only if there is unallocated space immediately after it. Shrinking is possible but may be limited. Third-party tools like GParted offer more flexibility and can move partitions, but moving is riskier and slower.
Why does my new 4 TB drive show only 3.6 TB?
This is normal. Hard drive manufacturers use decimal units (1 TB = 1,000,000,000,000 bytes), while operating systems use binary units (1 TB = 1,099,511,627,776 bytes). The difference is about 9.95%, so a 4 TB drive appears as roughly 3.6 TiB in Windows. Also, the partition table and file system overhead take up a small amount of space.
Related
Method: the standard formula for this calculation, rounded as each result states. See how the calculators work or report an error.
More cards in this drawer
- Kirin 990 vs A13 Bionic: Real-World Differences
- Why Do Some Ants Become Workers Earlier Than Others?
- Xiaomi Smart Speaker India: Models, Setup & Fixes
- TV Show Streaming Alerts: Setup Guide
- Is HTTPS More Secure and Reliable for Browsing?
- Email Theme Stationery: What It Is & How to Use It