Notion Hack for Complex Running Numbers that look like 2025_003

Learn how to create simple and complex running numbers for your Notion databases, including project, invoice, and offer numbers. This article provides step-by-step guidance and formulas to help you integrate year indicators and automate the numbering process effectively.

Mar 27, 2025
Notion Hack for Complex Running Numbers that look like 2025_003
In this article I’ll show you several ways to create easy and more complex running numbers for your Notion databases. In your agency this can be applied to – for example –
  • Project Numbers
  • Invoice Numbers or
  • Offer Numbers
If you are fairly new to Notion, you may gain some insights from part 1, where I’ll show you a simple way to add running numbers to your databases. If you are more advanced and you are looking to integrate the year or your client ID into your running numbers, skip to part 2, where I’ll show you a hack, that you possibly never thought off.
If you would rather watch a YouTube Tutorial instead of reading, I’m not judging. I got you covered here:
Video preview
Let’s go

Part 1 – Simple running numbers

The simplest possible way to create running numbers for your Notion databases is provided by Notion itself. Let’s say you have a database for all your invoices to your agency clients. Let’s keep it simple:
 
notion image

1. Using the Notion ID property for the simplest running number ever

If you are starting the database from scratch, you can simply create a new property and search for “ID”. Notion provides a native property that’s gonna count up, any time a new record is created in your database.
notion image
 
notion image
Nothing mindblowing here, but it’s a start.

2. Augmenting your Notion ID

Let’s say, a simple Number is not enough for you, but you want to augment it to integrate the year and leading zeros. For example
2024_001
Notion Formulas to the rescue!
First, create a Formula Property:
notion image
 
Second, edit the formula like this:
notion image
formatDate(prop("Created Time"), "YYYY")+"_"+padStart(prop("ID").toNumber(),3,0)
Notion Formula to make a more elaborate running number.
Here is a breakdown of what this formula does:
  1. It takes the time the record was created and formats it to only show the year.
  1. It adds an underscore as text as a divider.
  1. It converts the native ID to a number and uses the padStart function to add leading zeros, so the number will always come out to three digits (use four, if you are planning to send out more than 999 invoices that year).
 
And badabing, you have semi advanced running numbers in your database:
notion image
 
However, you’ll quickly run into problems using this system
  1. There is no way for the Formula to reset the running number to one, when the year changes.
  1. You have no control over the year categorisation as the date is drawn from the “Created Time Property”.
If we want to achieve this, we are going to have to hack the system.

Part 2 – Complex running numbers

Some context: My client is working with running numbers with a year indicator for
  1. offers sent
  1. project numbers and
  1. invoices
The running number resets every year and they wanted control over the year indicator, because at times a project entry is created in the database when acquired but only carried out the next year. This is how we solved it:

1. Create a “running numbers” database and link it

Create a new database called #running numbers and linked it to the invoice database with a relation property.
notion image
notion image
If you want to be really fancy, you can set up the relation so, that invoices can only have one entry of the running numbers, and the running numbers can allow unlimited entries of invoices. Also rename the relation in the invoice database as “Year”, to make it clear, what to select.

2. Count the entries and design your running numbers in a formula property

Next, create two formula properties in your #running numbers database. The first one – Called “Number of Invoices” is simply going to count the number of invoices linked like this:
prop("#Invoices").length()
The formula looks at the #Invoices property. As a relation with multiple entries, it is an array. The function lenght() simply counts how many entries are in it right now.
The second formula is to design your desired running number for the next entry in your database. Let’s call the property “Next compex Running Number”. Similar to before, the formula looks like this:
prop("Name")+"_"+padStart(prop("Number of Invoices"),3,0)
This time the formula makes use of the Name property in the #running numbers database as the year.
When you are done and have some invoices connected, your database should look like this:
notion image

3. Writing the running number to your invoice database via automation

Next, the complex running number is going to be written to your invoice database. We are going to do this with an automation.
First, create a text field in your #invoices database for your running number.
Then create an automation in your #invoices database. As a trigger, choose “Year is edited”. Let the automation than grab the “Next complex running number” from your #running numbers database and write it into your running numbers field.
To achieve this set the running number property up with a custom formula.
notion image
 
The custom formula reads…
notion image
This formula grabs the first entry from the “Year” property array of the trigger page and picks the property “Next complex Running Number” to enter in the field of the #invoices database.
notion image

Pro Tip: Use the same database hack for all of your databases with running numbers

Do you want to integrate running numbers to several databases? No problem. You can re-use the very same #running numbers database for your projects or offers as well.
 
notion image
notion image
I hope this article was useful.
 
 

 
 
🤙
Ready to automate your workflows?

If you want to push your business forward without burying yourself in repetitive tasks, let’s talk. I’ll help you create custom Notion environments and powerful automations—so you can focus on what matters most.