How to Change File Attributes in Windows 10/11 [2024 Guide]

Written By Farhan Max

File attributes are some settings options that determine whether a user or the operating system has permission to access and modify the files or not. It is quite a simple and straightforward approach to changing the file state.

Changing file attributes help you to safeguard your files from unwanted issues.how-to-change-file-attributes-in-windows 10-11-s

If other people have access to your computer, you need to ensure no one modifies your files. You can simply set the files to read-only mode to prevent others from modifying them. You can set the file attributes to be hidden so that no one can find them.

Well, in this article, I will guide you to change the file attributes on Windows 10/11. So without wasting any time, let’s get started!

Types of File Attributes

There are different types of attributes for files that you can find. But you can use a few from the properties menu of that file.

Here is the list of different file attributes:

AttributesWhat they do
Archive (A)It shows if the file has been modified since the last update
Hidden (H)You can hide any files from displaying on the File Explorer
System (S)Which indicates the file is crucial to the operating system
Read-only (R)It only gives permission to read the file
Compressed (C)It will compress the files automatically if the attribute is enabled
Encrypted (E)When enabled, your files will be encrypted
Directory (D)This will indicate the file as a subdirectory
Offline (O)Your files will be moved to the offline storage
Temporary (T)It indicates if the file is used for temporary storage

Check out the easiest way to Fix Windows 11 File History Element Not Found Error.

How to Change File Attributes in Windows 10/11

There are three file attribute-changing methods available out there. All of them are pretty easy but using the properties contextual menu is the most popular one. You can use any of them to change the file attributes.

Here are the methods to change the file attributes:

1. Use File Properties Menu

This is the most used method among all. You will need a minute to change the attributes of your files.

Here is how you can change file attributes using the properties menu:

  • Open Windows Explorer and locate your file.
  • Right-click on the file that you want to change file attributes.
  • Select Properties. right-click-properties
  • Check the boxes that are found at the bottom of the new properties window. properties-attributes
  • Click on the Advanced… button to access more detailed settings.
  • Change the attributes according to your desire. advanced-attributes
  • Click on Apply, then OK.

Here’s a complete guide on how to Disable File Compression on Windows 11/10.

2. Use Powershell

You can use Windows Powershell to change the file attributes. There are some cmdlets available that you can use to view, set, or remove them.

Here are the steps to change file attributes using Powershell:

  • Press Windows + X and open Windows Powershell.
  • Run the following cmdlet to view file attributes on Powershell. *

Get-ItemProperty -Path path_to_file

  • Run the following cmdlet to view all available information and combine the output. *

Get-ItemProperty -Path path_to_file | Format-list -Property * -Force

  • Run the following cmdlet to change file attributes. *

Set-ItemProperty -Path path_to_file -Name IsReadOnly -Value True

Quick Note: replace the ReadOnly with Archive, Hidden, Normal, and System, according to your need

*Note: replace the path_to_file with your actual file path.

Read more on how to Password Protect a File or Folder in Windows 11.

3. Use Command Prompt

The command prompt can change the file attributes using the command attrib. It comes prebuilt in the command prompt.

Here is how you can change attributes of files using Command Prompt:

  • Type Windows + R to open Windows Run.
  • Type cmd and hit Enter.
  • Use the following command to change the attribute to Read-only. *

attrib +R path_to_file

  • Type the following command to remove the Read-only attribute. *

attrib -R path_to_file

You can replace the R with other attributes according to your need. R or Read-only is used as an example.

*Quick Note: replace the path_to_file with your actual file path.

Related guide: Enable or Disable Offline Files in Windows 11.

Frequently Asked Questions

How do I change file attributes on a Mac?

You can change the file attributes on Mac by following the method:

Select a file > Get Info > click the drop-down arrow > select a user group > change the attributes.

What are 4 common file attributes for Windows?

In the file system directories, file attributes are maintained. You can typically find four common file attributes that are, Read-only, Hidden, System, and Archive.

How can files be protected?

You can use different methods to access any files. However, the most straightforward way of protecting the files is to associate Identity-dependent access with all the files and directories, called an access-control list, aka ACL. It shows the names of the users and the access to files that associate with each user.

Final Thoughts

That’s all from me. You can quickly change the file attributes by following any of those three methods. No matter which way you choose, your job will be done in no time.

Thanks for reading this article. Feel free to share any queries in the comment section below. I’ll try my best to resolve that.

Signing out.

About The Author
Farhan Max is a tech geek with a particular interest in computer hardware. He's been fascinated by gaming since childhood and is now completing his undergraduate studies while researching and testing the latest tech innovations. Alongside his love for all things geeky, Farhan is also a skilled photographer.

Leave a Comment