ARCHIVED: In Windows, what are file attributes, and how can I change them?
File attributes can be used to write-protect, hide, and unhide files, or in behind-the-scenes file maintenance:
- Read-only: Readable, but cannot be changed or deleted
- Hidden: By default, not displayed in a directory listing
- Archive: Used for selectively backing up or copying files; most helpful in DOS
- System: Flagged for use by the operating system; not usually displayed in a directory listing
Changing file attributes
View or change file attributes
To view or change the attributes of a file, right-click the file, and then click. In the "Attributes:" section, enabled attributes have checks beside them. Add or remove the checks from , , or to enable or disable these options. If you want to change the attribute, you need to do it from the command prompt.
Change file attributes from the command prompt
To determine what attributes are enabled on a file, you must use the
attrib command in the command prompt. In the
directory where the file is located, enter:
filename.ext with the full name of the file.
You should see something like:
A SHR FILENAME.EXT C:\FILENAME.EXT
The initials on the left stand for the first letter of the enabled attribute: A for Archive, S for System, H for Hidden, and R for Read-only.
To clear an attribute with
- (the minus sign), for example:
attrib -s -h -r filename.ext
Using the minus signs after
attrib in the above example
clears the System, Hidden, and Read-only attributes from the file. To
add an attribute, use
+ (the plus sign), as
attrib +h filename.ext
Using the plus sign in this example adds the Hidden attribute to the file.
This is document aift in the Knowledge Base.
Last modified on 2013-01-03.
- Fill out this form to submit your issue to the UITS Support Center.
- Please note that you must be affiliated with Indiana University to receive support.
- All fields are required.