How do I change the time zone of my Amazon RDS DB instance?
Last updated: 2020-08-25
I want to change the time zone of my Amazon Relational Database Service (Amazon RDS) DB instance to the local time zone. How do I change the time zone of my DB instance?
All Amazon RDS DB instances use UTC/GMT time by default, and changing your time zone is optional.
It’s a best practice to use the UTC time zone at the database layer. Because UTC doesn't observe daylight savings (DST), you don’t have to adjust the time later when it shifts.
If you must use a local time zone, convert the time zone at the application layer instead. Before changing your time zone, consult your database administrator or application team.
The steps required to modify the time zone of an Amazon RDS DB instance vary depending on the database engine.
Oracle – To modify the time zone for Amazon RDS Oracle DB instances, see Setting the database time zone. To change the time zone, Oracle Database Engine version 220.127.116.11.v4 is required.
PostgreSQL – To modify the time zone for Amazon RDS PostgreSQL DB instances at the database level, set the value of the time zone parameter in a custom parameter group. The time zone parameter takes the input form of UTC-X or UTC+X. X is the number of hours that the time zone is offset from UTC time.
Important: PostgreSQL processes time zones differently if you reference UTC-5 vs. "America/New_York". For example, the time zone "America/New_York" displays UTC-5. If you set the time zone as UTC-5, it updates as UTC+5. For more information, see the PostgreSQL documentation for Date/time types.
MySQL – For a DB instance running MySQL 5.5, 5.6, 5.7, and 8.0 set the time_zone parameter in the DB parameter group for the DB instance. All DB instances and read replicas that use the parameter group change to use the new time zone. You can't change the time zone for Amazon RDS MySQL versions prior to 5.5. By default, the time zone for RDS MySQL DB instances is Coordinated Universal Time (UTC). For more information, see Local time zone for MySQL DB instances.
Amazon Aurora – To change the time zone for an Amazon Aurora DB cluster, see Local time zone for Amazon Aurora DB clusters.
MariaDB – To change the time zone for a DB instance that runs MariaDB, set the time_zone parameter in the DB parameter group for the DB instance. All DB instances and read replicas that use the parameter group will use the new time zone. By default, the time zone for RDS MariaDB DB instances is Coordinated Universal Time (UTC). For more information, see Local time zone for MariaDB DB instances.
SQL Server – To change the time zone, specify the time zone when creating a new Amazon RDS for SQL Server instance. When creating the DB instance, expand the Additional configuration section, and choose your preferred time zone from the Time zone menu. You can’t modify the time zone after you create the instance. For more information, see Local time zone for Microsoft SQL Server DB instances.
SQL Server documentation for Date and time data types and functions (Transact-SQL)