TL;DR: In the Purgatory universe, there is no time-like concept, it is sometime after everyone has died (all at different times).
Let me explain a little bit more:
In the universe of the "Flash Sideways"/"Purgatory" (Where Ben is teacher, Hugo is happy, etc.), there is no "when". The most important hint is given by Christian in the scene in the church:
JACK: They're all...they're all dead?
CHRISTIAN: Everyone dies sometime, kiddo. Some of them before you, some...long after you.
JACK: But why are they all here now?
CHRISTIAN: Well there is no "now" here.
Since the scene at the end of season 2 (where Penny is called by the scientiest observing a magnetic anomaly) it is clear that they did not die during the plance crash.
Another example to emphasize the "no-time"-concept: When Desmond was in the huge magnetic field, he had a near-death experience and was in both universes "at the same time", which gives additional hints that this plot happens at no given time.
To answer your question when they died: Some died during the plane crash, then Boone died, etc. (just in the same order as seen in the show). As of the ending of the "on island"-plot, a lot of people are alive, but they will also die... eventually (e.g. depending on their age).
There is a theory that Jack is the last of them all to die (and this would explain why Jack needed the longest time to remember his time on the island and his life before): After Jack was at the heart of the island, he became the smoke monster for many many years.