We have a bunch of Mac at work that no longer require Xcode or command line tools so we'd like to remove them so the compilers aren't hanging around and we don't have to keep updating them when updates arrive.

In the old days, there was an install script (perl in /Developer) to remove the tools, but now that Xcode is an app store app you are left with the tools if you ever install them.

Can we clean this other than wiping the OS for macs running 10.10 and newer?

up vote 15 down vote accepted

The command line tools are now simply deleted by removing a folder:


This is documented officially by Apple.

If you have installed these tools another way or have prompts to upgrade them, consider searching for files named like /System/Library/Receipts/com.apple.pkg.CLTools.bom since that may be a receipt for a past installation of the tools that needs to be removed. I have never seen one of these files, but wanted to link to this other answer in case it helps others. Note, these files do not remove the tools, they may govern the prompt that dev tools are in need of an update.

  • 1
    However whenever there's a command line tools update, the App Store keeps showing up to update it. – adib Jun 13 at 22:53
  • Interesting @adib - I don’t get that behavior. I wonder if my use of xcode select to install the tools differs from your method with yours leaving a receipt? Either way, thanks for th comment. – bmike Jun 14 at 1:11
  • Long time ago I used a DMG (needed to install an older version of the command line tools, but that's another story). Now I can't seem to get rid of it. – adib Jun 15 at 1:26
  • Aah @adib - That makes sense. This question was for a new / recent install where you only go to the App Store and install Xcode - that will download the tools for you without leaving a receipt in my experience. – bmike Jun 15 at 19:55
  • 2
    @adlib: I had the same problem, just managed to fix it by deleting the bom files from /System/Library/Receipts: apple.stackexchange.com/questions/328034/… Perhaps that'll help you as well. – Kenny Lövrin Jun 18 at 9:15

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.