Detect a Notion Formula Date Range Overlap (Formula 2.0)

A notion formula date range overlap check evaluates two distinct timeline properties to determine if they share any active days. Because Notion cannot natively cross-reference timeline arrays, you must build a boundary condition formula to test if the start of the first date occurs before the end of the second, and vice versa.

To flag overlapping dates with a boolean true or false value, apply this Formula 2.0 dot-notation logic:

JavaScript

prop("Date A").dateStart() <= prop("Date B").dateEnd() and prop("Date A").dateEnd() >= prop("Date B").dateStart()

This mathematical test covers all possible collision scenarios: partial overlaps, exact matches, and complete encasements. If the conditions evaluate to true, the timelines are actively colliding.

Prerequisites

  • Notion Formula 2.0 Engine: This syntax relies on modern dot notation. Workspaces running legacy Formula 1.0 architecture require heavily nested parentheses to achieve the same result.
  • Enabled End Dates: Your Notion date properties must have the “Include end date” toggle activated. If a property contains only a single date, Notion treats the start and end time as the exact same millisecond.
  • Two Distinct Date Variables: You need two separate date properties within the same database row, or one local date property and one date array pulled via a rollup relation.

The Syntax Breakdown

This fix utilizes standard programming interval logic, executed natively within the Notion workspace.

  • prop("Date A").dateStart() — Extracts the opening timestamp of your first date range. Using dot notation keeps the extraction clean and readable.
  • <= prop("Date B").dateEnd() — The first boundary check. It confirms that the first event begins before (or exactly when) the second event finishes.
  • and — The mandatory logical bridge. Both boundary conditions must be true simultaneously for an overlap to exist.
  • prop("Date A").dateEnd() >= prop("Date B").dateStart() — The second boundary check. It confirms the first event finishes after (or exactly when) the second event begins.

Real-World Example: Enterprise Equipment Tracking

An operations manager at a media production agency tracks expensive camera equipment rentals in a central Notion database. The database logs the “Requested Checkout” date range alongside the “Maintenance Window” date range for each piece of gear.

The manager needs to prevent staff from booking a camera while it is scheduled for maintenance. Relying on visual calendar checks fails at scale.

Raw Data Table (Equipment Log)

Equipment IDRequested CheckoutMaintenance Window
CAM-01Oct 10 – Oct 15Oct 14 – Oct 16
CAM-02Oct 10 – Oct 12Oct 14 – Oct 16
CAM-03Oct 10 – Oct 18Oct 12 – Oct 14

The Formula / Script Apply

The manager creates a new Formula property titled “Conflict Warning” to run the collision check against the two date columns.

JavaScript

prop("Requested Checkout").dateStart() <= prop("Maintenance Window").dateEnd() 
and 
prop("Requested Checkout").dateEnd() >= prop("Maintenance Window").dateStart()

Output Table

Equipment IDConflict Warning (Boolean Output)Resolution
CAM-01trueDeny Request (Partial overlap on Oct 14-15)
CAM-02falseApprove Request (Zero overlap)
CAM-03trueDeny Request (Maintenance is fully encased)

The operations team can now filter the database view to automatically hide any request where the “Conflict Warning” property outputs true.

Common Related Errors & Fixes

  • Formula Returns True for Back-to-Back Events -> Cause: Using the <= and >= operators flags an overlap if Event A ends on October 10 and Event B starts on October 10. -> Fix: If your business logic permits back-to-back scheduling on the same day without considering it a conflict, remove the equals signs and use strictly < and >.
  • Type Mismatch Error with Rollups -> Cause: You attempted to test a local date property against a date property pulled through a Rollup. Rollups return an array (list), not a specific date primitive. -> Fix: You must apply the .first() or .last() array method to the Rollup property to extract a single date primitive before chaining the .dateStart() function: prop("Rollup Date").first().dateStart().

Key Takeaways

  • Detecting an overlap requires explicit boundary testing: Start A must precede End B, and End A must follow Start B.
  • Modern Formula 2.0 dot notation drastically improves the readability of interval math compared to legacy configurations.
  • Applying this formula natively within your database eliminates the need for expensive third-party automation tools like Zapier or Make to manage basic scheduling conflicts.

Frequently Asked Questions

Can I calculate the exact number of overlapping days?

Yes. To calculate the intersection duration, find the maximum of the two start dates and the minimum of the two end dates. You then wrap those two isolated values inside a dateBetween() function to extract the specific number of overlapping days.

Will this formula work if users are in different time zones?

Yes. Notion normalizes all date properties to UTC internally. When the formula engine compares the timestamps, it evaluates the absolute UTC values, preventing false positives caused by users viewing the calendar from different geographic regions.

Can I check for an overlap within a single multi-date property?

No. Notion date properties only hold one discrete range (a single start and end time). To test multiple recurring ranges against one another, you must architect your system using related databases, where each scheduling instance acts as an independent row that can be rolled up and evaluated via .map() arrays.

About the Architect: Grid and Formula

Lead Data Analyst and Workspace Automation Engineer at Grid & Formula. Specializing in Excel logic, Google Sheets architecture, and Notion database blueprints. I build and rigorously test the formula frameworks and error fixes published here, ensuring you get immediate, no-fluff solutions to your most complex data bottlenecks.