How to install Xcode command line tools on M1 Mac after upgrading to macOS Ventura?

I have tried the directions here: Install Xcode Command Line Tools Directly · Mac Install Guide, which incorrectly say to use: xcode-select –install (should be 2 dashes, not 1, before install).

  • What have you tried (e.g. using the App Store to download/install Xcode), how did it fail to work as expected?
    – nohillside
    Mar 7 at 16:11

1 Answer 1


In your Terminal, type:

xcode-select --install

This opens a window with a prompt. Follow the prompts. It then takes about 10 min to install.

Confirm that Xcode is installed:

Any of these methods will work:

pkgutil --pkg-info=com.apple.pkg.CLTools_Executables | grep version
# version:


xcode-select -p
# /Library/Developer/CommandLineTools


gcc --version
# Apple clang version 14.0.0 (clang-1400.0.29.202)
# Target: arm64-apple-darwin22.3.0
# Thread model: posix
# InstalledDir: /Library/Developer/CommandLineTools/usr/bin

You must log in to answer this question.

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