Skip to content

addSeconds

addSeconds(datetime, count) → datetime · Date & Time

Add (or subtract) seconds to a datetime.

  • datetime (required): the starting datetime

  • count (required): number of seconds to add. Negative to subtract.

utlx
addSeconds(now(), 3600)                  // 1 hour from now (3600 seconds)
addSeconds(now(), -1)                    // 1 second ago

Released under AGPL-3.0.