DEV Community

David Wippel
David Wippel

Posted on

Running node in UTC instead of local timezone

Set the env variable TZ to utc to run a node process in UTC instead of your local timezone. This enables debugging DateTime issues locally because servers often run in UTC.

e.g. TZ=utc node index.js

Top comments (5)

Collapse
 
cschliesser profile image
Charlie Schliesser

Doing the lord's work.

Collapse
 
jamondouglas profile image
Jamon Douglas

this comment made my day

Collapse
 
michaelxie profile image
Michael-Xie

Simple yet time saving, thank you!

Collapse
 
ferco0 profile image
Fernando Costa

Lost half day trying to understand a dumb thing, i am a dumb. God give you all you want, thanks.

Collapse
 
eddy_navarrete_cb9f395847 profile image
Eddy Navarrete

you rock dude, Thank you!!!