I installed Xcode 12.2 on my MBP. I installed it from App Store and it's 28 gb, while my Mac only has a SSD of 128gb.

I use vscode for all my c/c++ programs so is there a need for me to keep Xcode on my device?


3 Answers 3


For C/++ you only need the compiler (clang)/toolchain, which can be installed via commandline:

xcode-select --install


You'd need to install Xcode only if you wish to build native apps for macOS, iOS/iPadOS, watchOS or tvOS.

Compiling/Building C/C++ programs does not require you to have a full Xcode installation.


You can download and install the Command Line Tools to save space. These tools are enough to compile your project to an executable binary:

What is the Command Line Tools Package?

The Command Line Tools Package is a small self-contained package available for download separately from Xcode and that allows you to do command line development in macOS. It consists of the macOS SDK and command-line tools such as Clang, which are installed in the /Library/Developer/CommandLineTools directory.

You can remove the Xcode application and run the Terminal command:

 xcode-select --install

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .