Major and minor
The two main categories in music are major and minor. The single determining factor of what makes a chord major or minor is the third.
When the third is two wholetones (4 frets) above the root note the chord or scale is major.
When the third is one and a half tones (3 frets) above the root note the chord or scale is minor.
D major (root note is D, third note of scale is F#).
D minor (root note is D, flattened third note of scale is F).
Some chords such as guitar power chords are neither major or minor because the third isn't played.
D Power chord
Major chords are often described as happy and minor chords as sad but there is a whole range of expression in between these two extremes called modes. E.g. The Ionian mode sounds happier than the Mixolydian and the Locrian mode sounds sadder than the Dorian.