TradingView time and session settings

How to change timezone on TradingView

On TradingView Supercharts, open Chart settings, select Symbol, and change Timezone. You can also click the clock below the chart. Choose a named zone or Exchange to display the symbol's exchange time. This changes the displayed clock labels. Pine scripts cannot read that preference; their time conditions must use the intended timezone separately.

Review session logic with Pineify

Change the display and keep a reference bar

In the web or desktop Supercharts interface, open the settings gear, choose Symbol, and locate Timezone. Select the required zone and apply the setting. Exchange follows the exchange associated with the selected symbol. The clock below the chart provides another timezone selector.

  • Before changing it, select a closed bar and record its displayed date, time, and OHLC values.
  • Keep the symbol, interval, chart type, and regular or extended session selection fixed.
  • After changing Timezone, find that same bar and compare its clock label. Do not compare two bars merely because they both display 09:30.

Which time does each setting describe?

A timestamp identifies an instant; a timezone supplies its local calendar representation. Pine time values use milliseconds since the UNIX epoch. The exchange timezone is available as syminfo.timezone and supplies the default for calendar variables such as hour.

Time referenceRoleAudit question
Chart timezoneLabels on the chartWhich zone was used in the screenshot?
Exchange timezoneDefault calendar context in PineWhat does syminfo.timezone report for this symbol?
UNIX timestampAbsolute instant, independent of timezoneAre both observations anchored to the same millisecond value?
Explicit script timezoneContext supplied to a time calculationDoes the condition name the region it is meant to follow?

Worked example: one bar, several clock labels

These are calculated examples, not sampled market results. Assume a five-minute bar opens at the specified instant on each date. New York, UTC, and Shanghai columns describe that same opening instant within each row. The January and July rows are different bars.

  • January check: 09:30 plus five hours is 14:30 UTC; another eight hours gives 22:30 in Shanghai.
  • July check: 09:30 plus four hours is 13:30 UTC; another eight hours gives 21:30 in Shanghai.
  • On a chart with history for these dates, use the script below and inspect a bar in the Data Window. Compare its timestamp before and after changing the chart timezone.
DateNew YorkUTCShanghaiUNIX milliseconds
2026-01-1509:3014:3022:301768487400000
2026-07-1509:3013:3021:301784122200000

Use an explicit timezone in the session condition

This Pine Script v6 diagnostic shades bars whose opening times fall in a chosen weekday session. It exposes a separate Session time zone input and puts timestamp and hour values in the Data Window. The default is a demonstration of 09:30 to 16:00, Monday through Friday, not an exchange holiday calendar or a trading strategy.

  • The suffix :23456 restricts this example to Monday through Friday. Session input changes the hours; the weekday suffix stays fixed.
  • time() uses the supplied zone to interpret the session. A non-na result makes the shaded condition true. Omitting that argument would use the exchange timezone.
  • Match the session boundaries to chart bars. A coarse interval that straddles 09:30 is a different test from five-minute bars beginning at 09:30.
  • With America/New_York selected, the July example returns New York hour 9 and fixed UTC-5 hour 8. Switching the script input to UTC-5 excludes that 09:30 New York bar from the selected session.
Use standard five-minute candles to compare the same closed bar.pinescript
//@version=6
indicator("Time zone audit", overlay=true)
zone = input.string("America/New_York", "Session time zone", options=["America/New_York", "UTC-5", "UTC"])
sessionHours = input.session("0930-1600", "Session hours")
weekdaySession = sessionHours + ":23456"
inSession = not na(time(timeframe.period, weekdaySession, zone))
bgcolor(inSession ? color.new(color.teal, 88) : na)
plot(time, "Bar open UNIX milliseconds", display=display.data_window)
plot(hour(time, "UTC"), "UTC hour", display=display.data_window)
plot(hour(time, "America/New_York"), "New York hour", display=display.data_window)
plot(hour(time, "UTC-5"), "Fixed UTC-5 hour", display=display.data_window)
plot(inSession ? 1 : 0, "In selected session", display=display.data_window)

Check the daylight saving boundary

America/New_York follows the region's daylight saving rules; UTC-5 remains a fixed offset. For this example, changing only the chart timezone should preserve the session flag. Changing the script's Session time zone input is a separate experiment that can change it.

  • If a mismatch appears only in part of the year, inspect hardcoded UTC offsets before shifting the session hours.
  • If the wrong calendar day is selected near midnight, record the date as well as the hour in each relevant zone.
  • If an expected bar is absent, inspect the symbol's session and available history. A custom time filter cannot create missing bars.
  • Give Pineify the editable source, intended region, hours, weekdays, interval, and two failing timestamps. Ask it to make the timezone explicit and retain a diagnostic output for review.
Calculated test instantNew York clockFixed UTC-5 clockExpected session flags: New York / UTC-5
2026-03-06 14:30 UTC09:3009:301 / 1
2026-03-09 13:30 UTC09:3008:301 / 0
Where Pineify fits

Pine Script AI Coding Agent

Ask Pineify to revise an editable session condition with an explicit timezone, then inspect the generated code and compare its output on both sides of a daylight saving change.

Review session logic with Pineify

Frequently asked questions

Educational time-conversion and code examples. The script diagnoses session membership; it does not place orders or establish trading performance.

Sources and verification

Published by Pineify. Pineify is an independent product and is not affiliated with TradingView. Sources support the technical explanations; examples do not establish trading performance.