How to Get English Day and Month Names in the Terminal with LC_ALL=C
date writes day and month names in the language the computer is set to. In German, date -u '+%a, %d %b %Y' gives Do., 03 Dez. 2026, which a program that expects Thu, 03 Dec 2026 can't read. Writing LC_ALL=C in front of the command gives it English names, for that one command only.
This guide shows the difference with real output from zsh 5.9 and bash 3.2 on macOS. It sets a German locale for single commands, to show what a computer set to German prints.
Syntax
LC_ALL=C <command>
| Part | What it means |
|---|---|
LC_ALL | The variable that picks the locale, a set of language and format rules, for everything at once |
=C | The C locale. No spaces around = |
<command> | The command that runs with it, here date |
The macOS manual page man environ describes the two variables that matter here. LC_ALL: Overrides the values of LC_COLLATE, LC_CTYPE, LC_MESSAGES, LC_MONETARY, LC_NUMERIC, LC_TIME and LANG. LC_TIME: Locale to be used for interpreting dates input and for formatting output. And man setlocale says where C comes from: Only three locales are defined by default: the empty string "" (which denotes the native environment) and the "C" and "POSIX" locales (which denote the C language environment).
A variable written in front of a command applies to that command alone. The zsh manual: If a command name is given, the parameter assignments modify the environment of the command when it is executed.
The Example
You print the current date in the format HTTP uses for dates, first in the German locale de_DE.UTF-8 and then in the C locale, and check that neither setting stayed behind.
Step 1: Check That the German Locale Is There
locale -a | grep '^de_DE'
de_DE.UTF-8
de_DE.ISO8859-15
de_DE.ISO8859-1
de_DE
locale -a, in its manual's words, Lists all public locales. grep '^de_DE' keeps the German ones. de_DE.UTF-8 is the one this guide uses.
Step 2: See the Names in German
LC_ALL=de_DE.UTF-8 date -u '+%a, %d %b %Y %H:%M:%S GMT'
Do., 03 Dez. 2026 16:08:56 GMT
Do. and Dez. are the German short forms of Thursday and December. They're right for a German reader, but not for HTTP. RFC 9110, the HTTP standard, allows exactly seven day names, day-name = %s"Mon" / %s"Tue" / %s"Wed" / %s"Thu" / %s"Fri" / %s"Sat" / %s"Sun", and twelve month names, from Jan to Dec.
Step 3: Put LC_ALL=C in Front
LC_ALL=C date -u '+%a, %d %b %Y %H:%M:%S GMT'

Thu, 03 Dec 2026 16:08:58 GMT
The same format now gives Thu and Dec, the names RFC 9110 lists. Because LC_ALL overrides every other locale variable, this works whatever language the computer is set to.
Step 4: Check That It Applied to One Command Only
echo "${LC_ALL:-not set}"
not set

${LC_ALL:-not set} prints the value of LC_ALL, or the words not set when it has none. The zsh manual: If name is set, or in the second form is non-null, then substitute its value; otherwise substitute word. LC_ALL has no value: both settings ended with their command, and the rest of the terminal kept its own language. bash printed the same four results.
Common Mistakes
| Mistake | What happens | Do this instead |
|---|---|---|
LANG=C or LC_TIME=C while LC_ALL is set: LC_ALL=de_DE.UTF-8 LANG=C date -u '+%a %b' | Still German: Do. Dez., with LANG=C and with LC_TIME=C | Use LC_ALL=C, which overrides both |
LC_ALL=C after the command: date -u '+%a %b' LC_ALL=C | date: illegal time format: date took LC_ALL=C for a time to set | Put it in front of the command |
Spaces around =: LC_ALL = C date -u '+%a %b' | zsh: zsh: command not found: LC_ALL. bash: bash: LC_ALL: command not found | Write LC_ALL=C, with no spaces |
The first row is the reason to use LC_ALL and not one of the others. A computer can have LC_ALL set already, and then LANG and LC_TIME are ignored. In the second row, LC_ALL=C came after the command name, so it reached date as an operand. man date: If an operand does not have a leading plus sign, it is interpreted as a value for setting the system's notion of the current date and time. In the third, the spaces made LC_ALL the name of a command.
FAQ
Does date -R need LC_ALL=C?
No. LC_ALL=de_DE.UTF-8 date -u -R still printed English names: Thu, 03 Dec 2026 16:09:12 +0000. man date says -R prints its format while LC_TIME is set to the “C” locale.
Can I use POSIX instead of C?
Yes. man setlocale, quoted above, says that both denote the C language environment, and LC_ALL=POSIX date -u '+%a, %d %b %Y %H:%M:%S GMT' printed Thu, 03 Dec 2026 16:13:42 GMT, the same English names.
Conclusion
In the German locale, date printed Do., 03 Dez. 2026; with LC_ALL=C in front, the same command printed Thu, 03 Dec 2026, and the setting was gone after that one command. Use LC_ALL=C, not LANG or LC_TIME, whenever a program needs English day and month names.
Additional Resources
man environ,man setlocaleandman localein your terminal: the locale variables, the C locale and the list of locales on macOS.- RFC 9110, section 5.6.7: Date/Time Formats: the HTTP date and its day and month names.
- zsh manual: Shell Grammar: variables written in front of a command.
