I have published various layers using Geoserver 2.2.x with a PostGIS 2.0.1 (PostgreSQL 9.1.x) data store. Fields that only have date values and not time/timestamp related values are stored as date. After publishing my layers as wfs/wms and opening the table in the browser date vlues are displaying with a trailing 'Z'.

Is this a product of the geotools data store api that geoserver is using?

I think the geotools data store api is throwing a blanket over the data reading date as datetime, timestamp etc and the 'z' gets displayed for zulu time. I could be totally off on my geotools assumption but in PostgreSQL 'z' represents zulu or utc.

If the data source values are stored as date and have no time component why is there a trailing 'Z' in the date field?

Here multiple date values display with a trailing 'Z'


2 Answers 2


It appears you were/are on the right track as the 'Z' is used for a timezone indicator, here is the source I found that best answers your question

"Z" is kind of a unique case for DateTimes. The literal "Z" is actually part of the ISO 8601 datetime standard for UTC times. When "Z" (Zulu) is tacked on the end of a time, it indicates that that time is UTC, so really the literal Z is part of the time.

  • 1
    But this doesn't really explain why the timezone indicator is used for dates that have no time component.
    – rooby
    Commented Apr 13, 2020 at 4:30
  • because with out a timezone you don't know what day it is - consider when a day starts in UTC+24 as compared to UTC-23
    – Ian Turton
    Commented Feb 23, 2021 at 10:50

Start your Goserver with this Java option:


It will tell Geotools to not modify date objects (http://docs.geotools.org/latest/javadocs/org/geotools/factory/GeoTools.html#LOCAL_DATE_TIME_HANDLING).

You need to have at least version 15 of Geotools for this to work.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.