When used to express time relationships (like the English word “when”), als, wenn, and wann have quite different meanings, and they are not at all interchangeable.
The first two, als and wenn, are subordinating conjunctions as described in the previous section, and they are each used for different senses of time. Wenn carries the meaning of “when” in the sense of “whenever” or “if” when describing either the past or the present. Als is used to refer to a single event or block of time when referring to the past.
Wenn ich krank bin, bleibe ich zu Hause.
When(ever) I am sick, I stay at home. [or:] If I am sick, I stay at home.
Wenn ich krank war, blieb ich zu Hause.
When(ever) I was sick, I stayed at home.
Als ich krank war, blieb ich zu Hause.
When I was sick, I stayed at home.
The first sentence denotes repeated occurrences in the past or present, as well as potential occurrences in the future. The second sentence covers only repeated occurrences in the past, while the third refers to a particular single event in the past, in this case a particular bout with an illness.
Als sie Studentin war, war sie immer gut vorbereitet.
When she was a student she was always well prepared.
This usage of “als” refers to a single block of time in the past: one’s time as a student, one’s childhood, etc.
The question word wann is used solely in forming direct or indirect questions. Study the examples below:
Wann kommt der Bus? Ich weiß nicht, wann der Bus kommt.
When is the bus coming? I don’t know when the bus is coming.
Note that here the use of “wann” indicates either a direct or an indirect question.