2

The size of my ".shp.xml" file is 100 MB.

1) What is the purpose of the ".shp.xml" file?

2) Can I delete this file without affecting the data?

Comrade Che
  • 7,091
  • 27
  • 58

1 Answers1

6

You can delete the .xml file.

The .xml file contains the dataset's metadata. The metadata is the data about the data, or in other words, a description of the dataset you are using, such as who made the dataset, when it was made, how it is to be used, etc.

This file is completely optional, but make sure you really do not need it before you delete it. To be safe, maybe you can just cut out the file and place it somewhere else, and in case you need it later on you can just copy it into the folder that contains the shapefile.

BritishSteel
  • 6,637
  • 4
  • 38
  • 64
  • 3
    If you're using Esri software the .shp.xml is created when geoprocessing tools are used (project, repair geometry etc..) but you're right, it's quite possible that the .shp.xml could be shapefile metadata with important information like date of currency, accuracy, custodian etc.. so it's best to make sure it hasn't got important information before removing, especially if the file size is so large; Esri created tool metadata usually is in the order of bytes or k's of bytes not megabytes. – Michael Stimson Apr 19 '18 at 05:31
  • XML compresses pretty well, so if you don't want to delete it but you want to reclaim lots of space then zip it or gzip it might give you 90Mb of those 100Mb back. The biggest of the 200 .shp.xml files on my desktop is only 600kB though... – Spacedman Apr 19 '18 at 06:44
  • 2
    Having opened this .shp.xml file with the size of 100 MB in the browser, I found that It contains information about all my "append" operations. This is more than 40,000 lines with the path to all the files I add. That's why it's so huge. – Comrade Che Apr 19 '18 at 09:53