How to change time zone in MT5? - page 2

 
Md Mostakim Hossain Hira #:
How do I match my AI's time zone and my broker's time zone to a VPS in a different time zone. For example, my broker's time zone is GMT+3 and my VPS's time zone is +5.

You can't change your broker time zone, but you can change your EA's trading time settings to much those of your broker's, if your EA has such an option.

Your computer or VPS time zone is irrelevant.

 
You have to calculate it yourself: https://www.mql5.com/en/code/45287
Dealing with time (2) functions
Dealing with time (2) functions
  • www.mql5.com
Calculate DST for USA, EUR, AUD and RUB and the offset time of the broker automatically from the 70's until 2030 - even in the Strategy Tester of MQ.
 
how does one update the month from june to october
 
June Tumo #:
how does one update the month from june to october

The charts of the price, the price and the time of the price are related to the broker.
If the price on your charts are not refreshed so it means the following:

  • you did not connect to your trading account;
  • your broker is not proposing this symbol for traders.
 
Alain Verleyen #:

There is nothing to clarify. The answer you got is pretty clear.

The timezone is set by the broker (server), you can't change. Search for a broker who uses the timezone you want.

yes ttrue

 

Lo and behold, Aleksandr Slavskii coded an improved version of his Period Converter Mod service plainly named, Period Converter (attached below), that generates a time-offset custom chart (in addition to supporting creation of custom timeframes not natively supported in MT5). Aleksandr Slavskii kindly did so at my request. Although I'm not in the habit of posting unpublished source code of other developers, Aleksandr Slavskii expressly allowed me to do so. This work of his will finally put an end to decades of MT5 traders searching for a time zone fix.

The input, "Time shift in minutes", is exactly that. Regardless of the timeframe that you select, the timestamps of the generated bars are shifted by minutes. Therefore, use 60 for each hour of shift (offset). That input supports both positive or negative shift values, so no one on Earth is left out.

Please respect the copyright that is included in the code─as a matter of international law. Aleksandr Slavskii reserves all rights.

Files:
 
Sergey Golubev #:

The charts of the price, the price and the time of the price are related to the broker.
If the price on your charts are not refreshed so it means the following:

  • you did not connect to your trading account;
  • your broker is not promosing this symbol for traders.

Hi @Sergey Golubev

There is still a lot of confusion about MT5 bar's timezone.

I just tried to compare MT5 chart with Trading View chart (set as UTC-4 = NYC zone) and interestingly found MT5 chart follows exactly the same timezone i.e. UTC-4 = NYC zone.

Attached are png for your ready reference.

This also make sense for Broker to return timestamp in NYC timezone to align with most frequently traded timezone.

Can you please reconfirm my hypothesis.

Regards

Files:
 
Anil Varma #:

There is still a lot of confusion about MT5 bar's timezone.

I just tried to compare MT5 chart

You compared the MT5 of the broker (your MT5 was connected to the trading account of the broker), and the server (server = computer) of this broker is located in the US in NYC timezone. If you connect your MT5 to the other broker so you may get different time on the chart (depends on where their servers are located for example).

Forum on trading, automated trading systems and testing trading strategies

Time zone in signal trading history

Sergey Golubev, 2021.04.19 07:11

Timezone is related to the brokers. And the price is related to the brokers. And the chart is related to the broker.
Besides, your database is the broker's related as well.

The brokers want for the traders to use their (brokers') timezone which is the timezone of their servers.
Because this market (forex market and the brokers' market) is not unified.

Thus, -

  • the traders are trading account to their broker's time (which is the time on their charts)
  • waitching economic calendar news according to GMT + 0 (UTC),
  • and living account to the local time.

And it is the standard for traders during the many years (living on the time of location; trading on the time of the chart; economic news checking on GMT+0).

----------------

...