Set the time zone for a Linux/PHP website

Use the information in this article to change the time zone of your website running on Linux/PHP.

Default time zone

The default time zone for Rackspace Cloud Sites websites is Central Time (North America), and daylight saving time is observed. The UTC offsets are as follows:

  • Central Standard Time    UTC−6:00
  • Central Daylight Time     UTC−5:00

To change the time zone

To change your time zone on your Linux/PHP website, you must edit your .htaccess file to include the following line:

php_value date.timezone TIMEZONE 

For a comprehensive list of time zone values to use for TIMEZONE, go to

The following example shows the time zone set to Dubai:

php_value date.timezone Asia/Dubai

To test the change

Check the PHP information file, or run the following PHP file:

echo date('l jS \of F Y h:i:s A');

© 2015 Rackspace US, Inc.

Except where otherwise noted, content on this site is licensed under a Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License

See license specifics and DISCLAIMER