You will need to use both client-side and server-side technologies.
On the client side:
(pick one)
This works in most modern browsers:
Intl.DateTimeFormat().resolvedOptions().timeZoneThere is also jsTimeZoneDetect's
jstz.determine(), or Moment-Timezone'smoment.tz.guess()function for older browsers.
The result from either will be an IANA time zone identifier, such as America/Los_Angeles. Send that result to the server by any means you like.
On the server side:
(pick one)
Using TimeZoneInfo (on Non-Windows systems only):
TimeZoneInfo tzi = TimeZoneInfo.FindSystemTimeZoneById("America/New_York");Using TimeZoneConverter (on any OS):
TimeZoneInfo tzi = TZConvert.GetTimeZoneInfo("America/New_York");Using NodaTime (on any OS):
DateTimeZone tz = DateTimeZoneProviders.Tzdb["America/New_York"];