Reverting all Xcode settings to their original state

This is the officially recommended way to delta Xcode 5's preferences, type in Terminal.app:

defaults delete com.apple.dt.Xcode

That should restore Xcode to the state of its first launch.

(for older versions of Xcode the command was defaults delete com.apple.Xcode, i.e. without the dt in the middle).


Reset all XCode settings from command line by running following commands then restart XCode:

defaults delete com.apple.dt.Xcode
rm -rf $HOME/Library/Application\ Support/Developer/Shared/Xcode
rm -rf $HOME/Library/Saved\ Application\ State/com.apple.dt.Xcode.savedState
rm -rf $HOME/Library/Preferences/com.apple.dt.Xcode.*