How To Change the Timezone in n8n

If you’re running workflows in n8n that rely on accurate timestamps—like scheduling posts, tracking logs, triggering messages, or syncing databases—the correct timezone setting isn't just a preference, it's essential. Whether you're automating social media, emails, or managing calendar events, adjusting the timezone ensures consistent and predictable behavior. In this guide, you’ll learn how to change n8n timezone settings for different deployment environments including Docker, local installation, and cloud hosting. Let's get your automations aligned with your actual time.

Why Timezone Settings Matter in n8n

n8n uses the system’s timezone by default, which means your timestamps and schedule nodes reflect the timezone of the host machine. This can be problematic if:

  • Your server is in a different timezone than your primary users
  • You're using cron expressions for scheduled triggers
  • You're creating logs or reports based on specific timeframes
  • You want to avoid dealing with UTC conversion complexity

By learning how to change the n8n timezone, you ensure predictable and context-aware automations.


How to Check the Current Timezone in n8n

n8n doesn’t display the timezone in the UI out-of-the-box, but here’s how you can confirm it:

Method 1: Using the Function Node

Add a Function node to any workflow and paste this code:

return [
  {
    json: {
      currentTime: new Date().toString(),
    },
  },
];

Execute the node and observe the output. The string will typically include your current timezone offset, like GMT+0100 (Central European Standard Time).

This simple trick gives you clarity on what timezone your workflows are using.


How To Change n8n Timezone

How you change the timezone depends on how you installed or hosted n8n. Let’s break it down by installation type.

Docker-Based Setup

If you’re running n8n in Docker (as many users do), here’s what to do.

Step-by-Step for Docker Users

  1. Set the TZ environment variable in your Docker container. For example, update your docker-compose.yml like this:
services:
  n8n:
    image: n8nio/n8n
    environment:
      - TZ=America/New_York
    # Other configurations
  1. Restart the container:
docker-compose down
docker-compose up -d
  1. Use the same Function node test to verify the change.

Refer to the guide on installing n8n in Docker if you haven’t set up Docker yet.

Local or Desktop Installation

If you launched n8n via:

n8n

Then it inherits the system timezone by default. To change it:

macOS or Linux

  1. Check your timezone:
date
  1. Change it (example for Europe/London):
sudo timedatectl set-timezone Europe/London
  1. Reboot or restart terminal, then rerun:
n8n

Windows

  1. Open Settings → Time & Language → Date & Time
  2. Choose your timezone from the dropdown.
  3. Restart n8n via terminal.

Cloud Hosting (DigitalOcean, Google Cloud, VPS)

For cloud-deployed instances, you also need to configure at the server OS level (usually Linux).

Example: Ubuntu Server

sudo timedatectl list-timezones    # Browse available timezones
sudo timedatectl set-timezone Asia/Kolkata

After setting the timezone, restart your n8n service.

To learn how to deploy n8n on cloud platforms, check out the step-by-step DigitalOcean guide.


Timezone Settings in Cron Nodes

Even if your system has the correct timezone, don’t forget that Schedule nodes in n8n use UTC time by default unless specified otherwise.

Here’s what to do when using cron-based triggers:

Adjusting for Timezone Inside a Workflow

  • Use a Function node to convert UTC to your target timezone using JavaScript and the luxon or moment-timezone libraries (if you have them installed).
  • Alternatively, add time offset logic manually if you don’t want to add packages.
const now = new Date();
const offsetHours = -5; // For EST
now.setHours(now.getHours() + offsetHours);
return [
  {
    json: { adjustedTime: now.toISOString() },
  },
];

This adds flexibility when exact local time alignment is necessary.


Example Use Case: Posting on Social Media at Local Time

Let’s say you want to schedule a tweet or LinkedIn post every weekday at 9 AM local time.

  1. Set your server or container timezone to match your primary audience (e.g., America/Los_Angeles)
  2. Use a Schedule node with “Every weekday” at 09:00
  3. Add a logic node to customize your message or call the relevant API
  4. Ensure output matches timestamp expectations before execution

Following these steps ensures that "9 AM" always means what you expect.

For deeper social media automation, explore how to automate Instagram posts using n8n.


List of Common Timezone Strings

Below is a quick-glance table of common TZ values you can set in environment variables or the system:

Region TZ Value
US Eastern Time America/New_York
US Pacific Time America/Los_Angeles
Central Europe Europe/Berlin
India Asia/Kolkata
Japan Asia/Tokyo
UTC (Default) Etc/UTC

You can find the full list by running:

timedatectl list-timezones

Pro Tip: Add Timezone Tracking to Logs

If your workflows rely heavily on logging, add a helper Function node that appends the current timestamp with timezone-aware formatting. It’ll help you debug or audit processes later.

Example Function Node:

const d = new Date();
return [{ json: { timestamp: d.toLocaleString('en-US', { timeZone: 'America/New_York' }) } }];

Summary

Time settings in workflow automation shouldn’t be an afterthought. If you’re wondering how to change n8n timezone settings, the key takeaway is: the methodology depends on your deployment. For Docker, use the TZ variable. For local or cloud installs, change the system timezone.

With these adjustments, your Schedule nodes, timestamp logs, and integrations will finally operate on your time—literally.

For further improvements, you can learn how to automate YouTube video summaries using n8n or explore top workflow automation ideas.


FAQ

How do I change the timezone in n8n running inside Portainer?
Edit the container settings in Portainer and add an environment variable TZ with the desired timezone (e.g., Europe/London). Restart the container after saving.

Does n8n UI display the current timezone anywhere?
No, n8n does not show the server timezone in its UI. You’ll need to log the time using a Function node or view system-level settings.

Why is my scheduled workflow running at the wrong time?
This is usually due to a mismatch between the UTC-based Schedule node and your expected local time. Adjust your system timezone or convert UTC manually in your workflow logic.

Can I change the timezone without restarting n8n?
For most cases like Docker or local installs, you’ll need to restart the n8n instance or container to apply the timezone change.

Is it possible to run different workflows in different timezones?
Not natively. n8n applies the host timezone across all workflows. However, you can simulate timezone handling within Function nodes using libraries like moment-timezone or offset manipulation.

★★★★★
50+ fixes, templates & explanations
Stuck with n8n errors?
Node-by-node breakdown.
Copy-paste templates.
Beginner friendly.
Get the n8n Beginners Guide
Built by AgentForEverything.com
Comments
Join the Discussion and Share Your Opinion
Add a Comment

Leave a Reply

Your email address will not be published. Required fields are marked *

Newsletter
Get The Latest Agent Templates & Guides, Straight To Your Inbox.
Join the #1 AI Automation newsletter.