--- title: "addSeconds" slug: "tools-addseconds" updated: 2025-11-06T19:00:18Z published: 2025-11-06T19:00:18Z canonical: "docs.doc-know.com/tools-addseconds" --- > ## Documentation Index > Fetch the complete documentation index at: https://docs.doc-know.com/llms.txt > Use this file to discover all available pages before exploring further. # addSeconds ### tools.addSeconds Returns a DateTime object with a specified number of seconds added to today's date. Both positive and negative values are supported to either add or subtract the specified amount of time. ### Input Parameters | Name | Type | Required | Description | | --- | --- | --- | --- | | **value** | Number | Yes | Number of seconds to add or subtract | ### Returns Type: **DateTime** Returns a new DateTime value with the adjusted time component. ### Examples ``` // returns a new DateTime with 30 seconds added to the current time var date = tools.addSeconds(30); ``` ``` // returns a new DateTime with 30 seconds subtracted from the current time var date = tools.addSeconds(-30); ``` ### Remarks Use this helper function when you want to create offset DateTime values computed from today's date and time.