Connecting main clauses with "nicht ... sondern"

After a negation, you can use "sondern" to provide an alternative or contrast.

Examples:
Harry ist nicht mutig, sondern feige.
Dr. Anderson ist kein Arzt, sondern ein Mörder.

"sondern" is a conjunction that connects two main clauses. If the verb and/or subject is the same in both sentences, then they can be dropped from the second part.
That makes the compound sentence shorter.

Without conjunction:     Harry ist nicht mutig.           Er ist feige.
With conjunction:   Harry ist nicht mutig,   sondern   er ist feige.
Shortened:   Harry ist nicht mutig,   sondern   feige.

Sometimes the negation doesn't apply to the whole sentence, but to only part of it or a group of words or a single word. "sondern" can still be used to provide a contrast.

Example:
Ich habe den Stein nicht geworfen, sondern eine Frau.

In this case, the pronoun "ich" is negated and so only "eine Frau" is added.

Example:
Ich habe den Stein nicht geworfen, sondern mitgebracht.


In the above sentence, only the past participle is negated.

The part of the sentence to be negated is often pronounced more heavily either through stronger emphasis or through word order.

Example:
Question: Wieso haben Sie das Fenster kaputt gemacht?
Reply: Das war ich nicht, sondern der Stein. (= regular word order)
Reply: Das war nicht ich, sondern der Stein. (= emphasized word order)

"sondern" always requires a comma

No matter whether "sondern" introduces a whole clause or just a single word, it is always preceded by a comma!