Parfois vs. quelquefois vs. de temps en temps vs. des fois

The French language has several ways to express the idea of 'sometimes', with each having slight nuances in usage and context. The words 'parfois', 'quelquefois', 'de temps en temps' and 'des fois' all translate as 'sometimes' in English, but are used differently in various contexts.

Parfois

'Parfois' is one of the most frequently used ways to say 'sometimes' in French. It can be used in both written and spoken French, seamlessly fitting into sentences without sounding too literary or casual.
Parfois, je me sens seul.
(Sometimes, I feel lonely.)
Parfois, il est préférable de ne rien dire.
(Sometimes, it's better to say nothing.)

Quelquefois

'Quelquefois' translates to 'sometimes' as well but is more formal and often used in written French rather than spoken conversation. It implies a lesser frequency than 'parfois'.
Quelquefois, je lis un livre avant de dormir.
(Sometimes, I read a book before going to sleep.)
Quelquefois, la vérité est plus étrange que la fiction.
(Sometimes, truth is stranger than fiction.)

De temps en temps

The phrase 'de temps en temps' also translates to 'sometimes', emphasizing the passage of time between occurrences. It gives the sense of an event happening from time to time, less frequently than something happening 'parfois' or 'quelquefois'.
De temps en temps, j'aime boire du thé au lieu du café.
(From time to time, I like to drink tea instead of coffee.)
De temps en temps, nous devons prendre du recul et réévaluer nos objectifs.
(From time to time, we need to step back and reevaluate our goals.)

Des fois

'Des fois' is an informal way to say 'sometimes' in French. It's more conversational and less formal than the other expressions, often used in colloquial speech.
Des fois, je regarde la télé toute la journée.
(Sometimes, I watch TV all day.)
Des fois, on fait des erreurs.
(Sometimes, we make mistakes.)

Summary

'Parfois', 'quelquefois', 'de temps en temps' and 'des fois' all translate as 'sometimes', each with nuances in formality and frequency.