Documentation

gwp_date_created

The gwp_date_created Merge Tag returns a modified date time relative to the date time when the entry was created in the desired format.

Options

modify (optional)For available date time modifications, see https://www.php.net/manual/en/datetime.formats.php#datetime.formats.relative.
format (optional, default =’Y-m-d H:i:s’)For an explanation of available format options, see https://www.php.net/manual/en/datetime.format.php. Regular character can be escaped using a backslash /. For example: ‘d/m/Y\ \a\t\ H:i:s’.
timezone (optional, default is WordPress timezone setting)For available timezones, see https://www.php.net/manual/en/timezones.php. For example: Europe/Amsterdam
It is also possible to use an offset value: +0200

Examples

{gwp_date_created modify="+1 day" format="d-m-Y H:i:s"}

When the entry is created on 2021-03-30 12:21:23 this returns ’31-03-2021 12:21:23′


{gwp_date_created modify="-1 day" format="d-m-Y"}

When the entry is created on 2021-03-30 12:21:23 this returns ’29-03-2021′

Frequently Asked Questions

How do I display the exact date/time when an entry was created?

You can use the {gwp_date_created} merge tag to show when an entry was created. By default, it returns the date and time in Y-m-d H:i:s format.

Example:
{gwp_date_created}

How can I show the entry date in a specific format?

You can customize the display format using the format option.
For example, to show the date in day/month/year hours:minutes:seconds format:

Example:
{gwp_date_created format="d/m/Y H:i:s"}

Can I display a date relative to the entry date?

Yes! The modify parameter supports a wide range of relative date and time phrases — not just simple day offsets. You can shift the displayed date using flexible terms like:
Specific days → “last monday”, “next friday”
Month-based → “first day of next month”, “last day of previous month”
Week-based → “this week”, “next week”
Advanced → “third wednesday of this month”
You can also combine these formats for very specific adjustments.

Example:
{gwp_date_created modify="first day of next month" format="d-m-Y"}
{gwp_date_created modify="last monday" format="d-m-Y"}
{gwp_date_created modify="third wednesday of this month" format="d-m-Y"}

How do I change the timezone of the displayed date?

You can apply the timezone option to display the date in your desired timezone.

Example:
{gwp_date_created timezone="Europe/Amsterdam" format="d-m-Y H:i:s"}

Can I use {gwp_date_created} as a field default value?

 Yes! You can set {gwp_date_created} as the Default Value of any supported field (such as a Hidden field) to store the entry creation time in the database.

Example:
Default Value: {gwp_date_created}

Where can I find all supported date formats and modifiers?

You can view a full guide on supported formats, modify options, and usage examples in our documentation:
GravityWP Date Format & Modifiers Reference

Last updated: 18-07-2025

This field is for validation purposes and should be left unchanged.
Advanced Merge Tagsv1.9.3

To use the functionalities described in this documentation, you'll need to get the GravityWP - Advanced Merge Tags add-on.

Read more