Determine if a date falls within a start and end date
=AND(date_to_check>=MIN(start_date,end_date), date_to_check<=MAX(start_date,end_date))This function checks whether a date is within a start and end date range, including both endpoints. It's useful for filtering records, validating timelines, and building date-based logic in spreadsheets without repeatedly writing comparisons. For example, if A2 contains "2026-01-15", B2 contains "2026-01-01", and C2 contains "2026-01-31", then =DATE_IN_RANGE(A2, B2, C2) returns TRUE. If A3 contains "2026-02-01" with the same start/end values, it returns FALSE.
Use the inputs below to create DATE_IN_RANGE as a reusable custom function in Google Sheets.
Learn how to add custom functions to Google SheetsDATE_IN_RANGE
Determine if a date falls within a start and end date
=AND(date_to_check>=MIN(start_date,end_date), date_to_check<=MAX(start_date,end_date))
date_to_check
start_date
end_date
Date to evaluate
A2
Start date of the range (inclusive)
B2
End date of the range (inclusive)
C2
Other functions in the same category: Date & Time Operations
Returns TRUE if two date ranges overlap
Calculates the difference between two dates in whole weeks.
Checks if the day and month of a date fall within a date range
Counts occurrences of a weekday between two dates
Converts a time duration in minutes to a readable format (e.g., 1 hr 30 min)
Returns TRUE if a date falls on Monday through Friday
Named functions enable the creation of custom, reusable formulas that mimic built-in functions, streamlining calculations and data manipulations. These functions simplify complex formulas, making spreadsheets more readable and less prone to errors. By encapsulating intricate logic within a single function call, they enhance consistency across your data. Utilizing named functions reduces the need to write lengthy formulas repeatedly, thereby improving workflow efficiency and productivity in data analysis and management.
Download and import — fastest way to add the function but does not include argument descriptions and examples
Follow these simple steps to download and import a function into your spreadsheet. This method is the quickest and easiest way to add the named function to your Google Sheets document, but will not include the argument description and examples.
Once added, the function will be ready to use in your document like any other built-in function. Simply type the function name and provide the required inputs to use it in your calculations.
Copy and paste — copy and paste each property one at a time
Follow these simple steps to integrate a custom named function into your spreadsheet:
Once added, the function will be ready to use in your document like any other built-in function. Simply type the function name and provide the required inputs to use it in your calculations.