How to Remove File Attribute 'Where From' After Downloading on Mac

Published July 05, 2024

remove PDF file attribute How to remove file attribute Where from from PDF or any other downloaded file

Blog post to remove certain extra file attributes if you have downloaded it from a website. Useful if you have downloaded a file with a long or ugly URL and you want to remove it before sharing.

File properties

If you download a PDF file or any other file from a website and then right-click on it and select Properties, you may find extra properties like Where from.

On the Mac, click on the filename and press command+i, you may find extra properties in the PDF file. If you have downloaded a PDF file from the Internet, you may see a new attribute called Where from with a long and/or ugly URL.

remove PDF file attribute

This is an extended file attribute that is added to the metadata of the file when it is downloaded.

You will see this for PDF files, DOC files, media files, video files as well as other files.

How to display all extended attributes in macOS

Open up Terminal in Utilities and run the xattr command:

xattr FILENAME

If the name of the file is 2013-2014_Contest_4_Numble.pdf, and if ou want to see which attributes are being used, go to the directory of that PDF file and run this:

xattr 2013-2014_Contest_4_Numble.pdf

The output can be something like this:

com.apple.macl
com.apple.metadata:kMDItemWhereFroms
com.apple.quarantine

To see the key and values of those extended attributes, we use xattr -l FILENAME.

$ xattr -l 2013-2014_Contest_4_Numble.pdf
com.apple.macl:
com.apple.metadata:kMDItemWhereFroms: bplist00ïżœ_Ahttps://aruljohn.com/problems/acsl/2013-2014_Contest_4_Numble.pdf

com.apple.quarantine: 0081;66861ef9;Chrome;

How to remove the Where from attribute from a PDF file

To remove there Where from attribute on a Mac, we use xattr -d com.apple.metadata:kMDItemWhereFroms FILENAME.

$ xattr -d com.apple.metadata:kMDItemWhereFroms 2013-2014_Contest_4_Numble.pdf

It will return a blank response if successful. That means, the Where from attribute has been deleted from the PDF file.

Verify that the Where from attribute is deleted

Run this command to verify that the Where from attribute has really been deleted.

$ xattr -l 2013-2014_Contest_4_Numble.pdf 
com.apple.macl: 
com.apple.quarantine: 0081;66861ef9;Chrome;

In Finder, you can also select the file and press the control+i keys. You will see this:

deleted PDF file attribute Where from

Can I remove the Where from attribute from a DOCX file?

Yes, you can. As an example, let us download a DOCX file from https://www.nps.gov/teachers/classrooms/upload/DEPO_ExploringClimateScienceClimateChange.docx. From the same directory as this DOCX file, run this:

xattr -l DEPO_ExploringClimateScienceClimateChange.docx

Your output will be this:

com.apple.macl: 
com.apple.metadata:kMDItemWhereFroms: bplist00ïżœ_]https://www.nps.gov/teachers/classrooms/upload/DEPO_ExploringClimateScienceClimateChange.docx_https://www.google.com/
                                                         k
com.apple.provenance: 
com.apple.quarantine: 0081;6686ac1d;Chrome;

To get rid of the Where from attribute from the metadata:

$ xattr -d com.apple.metadata:kMDItemWhereFroms DEPO_ExploringClimateScienceClimateChange

Verify that the attribute has been deleted:

$ xattr -l DEPO_ExploringClimateScienceClimateChange.docx 
com.apple.macl: 
com.apple.provenance: 
com.apple.quarantine: 0081;6686ac1d;Chrome;

What other file types can I remove this Where from?

You can remove this Where from attribute from the metadata of PDF, DOCX, DOC, CSV, JSON, and pretty much every file type that is out there.

If you cannot remove it, please let me know.

Conclusion

If this command worked or did not work for you on the Mac, let me know. Thanks for reading.

Related Posts

If you have any questions, please contact me at arulbOsutkNiqlzziyties@gNqmaizl.bkcom. You can also post questions in our Facebook group. Thank you.

Disclaimer: Our website is supported by our users. We sometimes earn affiliate links when you click through the affiliate links on our website.

Last Updated: July 05, 2024.     This post was originally written on July 04, 2024.