Date.IsInCurrentMonth

Date

Returns true if the date falls within the current calendar month.

Examples on this page use shared sample tables. View them to understand the input data before reading the examples below.

Syntax

Date.IsInCurrentMonth(dateTime as any) as logical

Parameters

NameTypeRequiredDescription
dateTimeanyYesA date, datetime, or datetimezone value to test.

Return Value

logicaltrue if the date is in the current month, false otherwise.

Remarks

Date.IsInCurrentMonth returns true if the input date falls within the same year and month as today's date (DateTime.LocalNow()). It matches the entire calendar month from the first to the last day, inclusive — including future dates within the current month. This function is re-evaluated on each query refresh.

Note that this function includes future dates in the current month. If you need only dates up to and including today, use Date.IsInYearToDate restricted to the current month, or add and [OrderDate] <= Date.From(DateTime.LocalNow()) to the filter.

In Power BI Service scheduled refreshes and cloud Dataflows, the "local" time is the server's timezone (usually UTC). If your data dates are in a different timezone, the month boundary may not align with what you expect. This is the same caveat that applies to all Date.IsIn* functions.

Examples

Example 1: Filter this month's orders

Table.SelectRows(
    Sales,
    each Date.IsInCurrentMonth([OrderDate])
)
Result
OrderID
OrderDate
1403/1/2026
2413/7/2026
3423/8/2026

Example 2: Flag current-month rows

Table.AddColumn(
    Sales,
    "IsCurrentMonth", each Date.IsInCurrentMonth([OrderDate]), type logical
)
Result
OrderID
OrderDate
IsCurrentMonth
1382/20/2026FALSE
2403/1/2026TRUE
3423/8/2026TRUE

Example 3: Filter month-to-date orders only (excluding future dates this month)

let
    Today = Date.From(DateTime.LocalNow())
in
    Table.SelectRows(
        Sales,
        each Date.IsInCurrentMonth([OrderDate]) and [OrderDate] <= Today
    )
Result
OrderID
OrderDate
1403/1/2026
2413/7/2026
3423/8/2026

Compatibility

Power BI Desktop Power BI Service Excel Desktop Excel Online Dataflows Fabric Notebooks