Note: This functionality is currently available to users using Line Item Calculations - read more about Upgrading Templates to use Line Item Calculations
About line item properties
HubSpot line items can have multiple date properties, but comes with some defaults. Each line item property behaves just like any other property in HubSpot, such as a Deal or Contact property, and you can use them in workflows and in reporting.

The most common use cases are:
- Billing Start Date (built in) - used to show customers when payments are made, can be picked up by invoicing tools such as Invoice Stack
- Contract Start Date - manage when contracts start and finish in cases where that's different to when an item is actually billed
- Renewal Date - spot when items are up for renewal or when contracts end
- Event Date, Service Date or Appointment Date - to track when a billable activity takes place
You can add line item properties just like you would for a deal or contact from the properties settings - but note line item properties are listed as "Product" in the editor. Find out more about the difference between products and line items on the HubSpot Knowledge Base.
To make these properties visible in your quote or line items editor - you can edit the columns that show in HubSpot.
Populate dates using LinePilot's built-in dynamic date tokens
LinePilot has dynamic date tokens built in to allow you to quickly populate a line item property, based on the date the template runs - just use the Insert menu to do this.

At present we offer the following options:
- today - the date the template runs
- startOfMonth - the first day of the month the template runs
- endOfMonth - the last day of the month the template runs
Need a different date? We're adding more options so would love to hear your feedback - alternatively - look at the options below.
Populate dates using deal properties
If you'd like to use a date from elsewhere (for example one that's stored on the Deal) - you can use the Insert menu to choose Deal property and specify a property from your HubSpot deal.
This works really well if you've already calculated the date you need, for example through a workflow. For example, you may want to set the billing start date to be the same as the deal close date.
Note that if you're populating a property from something that's not a date property itself (e.g. populating from a text field) - then you need to be careful about setting the right format (this is a standard known as the ISO date format)
- For date properties: YYYY-MM-DD
- For date time properties: YYYY-MM-DD or YYYY-MM-DDTHH:mm:ss
If your date isn't in this format - then you can use the format date function - see further down the page for more info.
Calculate date properties in HubSpot
Let's say you wanted to create custom dates, e.g. set the billing start date to be 30 days after a course begins. LinePilot's functions allow you to do date calculations really easily. You can find more information about using Line Item Calculations in this article.
See below for a list of the date-specific functions:
Function | Definition and Example |
---|---|
format_date(date, format) | Format a date using date tokens - see below for available tokensformat_date(Today,"mmm yy") |
add_days(date,daysToAdd) add_months(date,monthsToAdd) add_years(date,yearsToAdd) | Adds days/months/years to a supplied date. Negative values are accepted as welladd_months(Contract Start Date,Term in Months) |
days_between(date1,date2) | Get the difference in days between 2 datesdays_between(Close Date,Contract Start Date) |
Formatting Dates
See below for a full list of date tokens that can be used with the format_date function.
For example - say you wanted the line item description to be the close date as August 25:format_date(Close Date,"LLLL yy")
Standalone token | Format token | Description | Example |
---|---|---|---|
S | millisecond, no padding | 54 | |
SSS | millisecond, padded to 3 | 054 | |
u | fractional seconds, functionally identical to SSS | 054 | |
uu | fractional seconds, between 0 and 99, padded to 2 | 05 | |
uuu | fractional seconds, between 0 and 9 | 0 | |
s | second, no padding | 4 | |
ss | second, padded to 2 padding | 04 | |
m | minute, no padding | 7 | |
mm | minute, padded to 2 | 07 | |
h | hour in 12-hour time, no padding | 1 | |
hh | hour in 12-hour time, padded to 2 | 01 | |
H | hour in 24-hour time, no padding | 9 | |
HH | hour in 24-hour time, padded to 2 | 13 | |
Z | narrow offset | +5 | |
ZZ | short offset | +05:00 | |
ZZZ | techie offset | +0500 | |
ZZZZ | abbreviated named offset | EST | |
ZZZZZ | unabbreviated named offset | Eastern Standard Time | |
z | IANA zone | America/New_York | |
a | meridiem | AM | |
d | day of the month, no padding | 6 | |
dd | day of the month, padded to 2 | 06 | |
c | E | day of the week, as number from 1-7 (Monday is 1, Sunday is 7) | 3 |
ccc | EEE | day of the week, as an abbreviate localized string | Wed |
cccc | EEEE | day of the week, as an unabbreviated localized string | Wednesday |
ccccc | EEEEE | day of the week, as a single localized letter | W |
L | M | month as an unpadded number | 8 |
LL | MM | month as a padded number | 08 |
LLL | MMM | month as an abbreviated localized string | Aug |
LLLL | MMMM | month as an unabbreviated localized string | August |
LLLLL | MMMMM | month as a single localized letter | A |
y | year, unpadded | 2014 | |
yy | two-digit year | 14 | |
yyyy | four- to six- digit year, pads to 4 | 2014 | |
G | abbreviated localized era | AD | |
GG | unabbreviated localized era | Anno Domini | |
GGGGG | one-letter localized era | A | |
kk | ISO week year, unpadded | 14 | |
kkkk | ISO week year, padded to 4 | 2014 | |
W | ISO week number, unpadded | 32 | |
WW | ISO week number, padded to 2 | 32 | |
ii | Local week year, unpadded | 14 | |
iiii | Local week year, padded to 4 | 2014 | |
n | Local week number, unpadded | 32 | |
nn | Local week number, padded to 2 | 32 | |
o | ordinal (day of year), unpadded | 218 | |
ooo | ordinal (day of year), padded to 3 | 218 | |
q | quarter, no padding | 3 | |
quarter, padded to 2 | 03 | ||
D | localized numeric date | 9/4/2017 | |
DD | localized date with abbreviated month | Aug 6, 2014 | |
DDD | localized date with full month | August 6, 2014 | |
DDDD | localized date with full month and weekday | Wednesday, August 6, 2014 | |
t | localized time | 9:07 AM | |
tt | localized time with seconds | 1:07:04 PM | |
ttt | localized time with seconds and abbreviated offset | 1:07:04 PM EDT | |
tttt | localized time with seconds and full offset | 1:07:04 PM Eastern Daylight Time | |
T | localized 24-hour time | 13:07 | |
TT | localized 24-hour time with seconds | 13:07:04 | |
TTT | localized 24-hour time with seconds and abbreviated offset | 13:07:04 EDT | |
TTTT | localized 24-hour time with seconds and full offset | 13:07:04 Eastern Daylight Time | |
f | short localized date and time | 8/6/2014, 1:07 PM | |
ff | less short localized date and time | Aug 6, 2014, 1:07 PM | |
fff | verbose localized date and time | August 6, 2014, 1:07 PM EDT | |
ffff | extra verbose localized date and time | Wednesday, August 6, 2014, 1:07 PM Eastern Daylight Time | |
F | short localized date and time with seconds | 8/6/2014, 1:07:04 PM | |
FF | less short localized date and time with seconds | Aug 6, 2014, 1:07:04 PM | |
FFF | verbose localized date and time with seconds | August 6, 2014, 1:07:04 PM EDT | |
FFFF | extra verbose localized date and time with seconds | Wednesday, August 6, 2014, 1:07:04 PM Eastern Daylight Time | |
X | unix timestamp in seconds | 1407287224 | |
x | unix timestamp in milliseconds | 1407287224054 |
Need Assistance?
Our team are happy to help if you need help working out how best to use dates in LinePilot - just reach out to us at support@linepilot.co