How to create a file of a certain size in Windows

You may need to create a file of a certain size in Windows when testing the writing speed of disks, checking quotas on the size of transferred or stored data. Usually such files are dummy files representing a continuous block of zeros. They can have any extension or not have it at all. The latter is unimportant, the main thing is that they occupy a given amount of disk space.

In Windows, you can create such files using the built-in fsutil.exe console utility. You can also use third-party alternatives with a graphical interface and batch mode support.

Create a file of a certain size on Windows

  1. Open the command prompt or Windows Terminal.
  2. Type the following command fsutil file createnew <file path> <size>.Create A File Of A Certain Size On Windows 1
  3. Replace <file path> with the full path to the dummy file you want to create.
  4. Specify <size> in bytes for your new file.

For example, the command fsutil file createnew D:\file.txt 1024000 will create a new file of 1MB in the root of the D: partition.The File Of A Certain Size On Windows

You can also use some of the third-party tools. Sometimes third-party tools are more useful than the built-in fsutil tool, as they offer extra features. We reviewed those that we like below.

Blank File Generator

Blank File Generator

Blank File Generator is a portable app. Blank File Generator does not support batch mode. But it supports additional options like writing in blocks. The user can also choose the method of filling the file: with zeros, spaces or random bytes. Block writing can be used to improve performance when creating large files, such as 500 MB or more. The larger the block, the faster the file will be created. By default, files created in Blank File Generator have the EAT extension.

Dummy File Creator

Dummy File Creator

The Dummy File Creator app does not require installation. It can create dummy files in batch mode.

You can specify the size of the generated file in bytes, kilobytes, megabytes and gigabytes. It also allows you set set a name with an extension (the default extension is .dummy), and the number of files that will be automatically named.

Create Dummy Files

Create Dummy Files

This dummy file creation tool differs in that it can assign attributes to the created files. For example, the resulting file be get read-only, archived, hidden, and even system attributes. It also shows basic information about hard disk partitions, such as the serial number of the disk, volume label and free space.

The name and extension of the generated file can be specified manually. The file contents can also be customized. Additionally, the user can set the file size in bytes, kilobytes, megabytes and gigabytes. It also supports batch operation and overwriting of already created files. The main disadvantage of Create Dummy Files is that it is slow: it takes almost two minutes to create a single 100 MB file.

FileFiller

FileFiller

FileFiller is an old portable utility known since the XP days for creating dummy files of a given size. It creates files in bytes, kilobytes, megabytes, and gigabytes. The files can contain spaces, random values, and ASCII characters. By default, files generated by FileFiller have the DAT extension.

Random Garbage File Creator

Random Garbage File Creator

The last tool we want to review is Random Garbage File Creator. It is a portable app for creating files with a random set of data and a random size.

It doesn’t support creating files of a known size. The “Max. number of bytes” specifies only the maximum size of the generated file. That is, if you specify 2000 bytes in this field, Random Garbage File Creator will create a file of random size from 1 to 2000 bytes.

In the “Number of files to create” field, you can specify the number of files to be created. When creating each new file, the utility will ask for a name an/or extension.

Looks like you've read the post to the end. If you enjoyed it, please share it. You would greatly help our blog to grow!

Author: The MFTNEXT Team

The MSFTNEXT project is a small team of authors who love to engage with the latest technology and gadgets. Being passionate Windows bloggers, we are happy to help others fix their system issues.

Leave a Reply

Your email address will not be published.

css.php