How to check if today is starting day of month using Power Automate?

Power Platform is for citizen developers. For Power Users who are masters of their business process but lacks the technical background to build an application out of that knowledge, Power platform have provided a level playing field.

Last few posts, I wrote based requests of enthusiastic citizen developers. This is one more query I received from one such enthusiastic developer who have just started exploring the world of Power Platform.

The requirement is very simple. We need to determine within a Power Automate flow if today is the starting date of the month. But how do we do it?

To demonstrate this, I created an instant cloud flow. As a first step, I initialized a string variable

  • Name : StartOfMonth
  • Type : string
  • Value: startOfMonth(utcNow(), ‘dd/MM/yyyy’)

The format specified in the value can be anything. Really does not matter. However what is important here is the function – startOfMonth where I am passing the current date and time as the first parameter

start day of the month using Power Automate

In the next step, I will compare current date with the variable value from earlier step. Observe I have used the formatDateTime function with the same date format used earlier to make sure we have the correct comparison.

formatDateTime(utcNow(), 'dd/MM/yyyy')
start day of the month using Power Automate

Basically, you could have done all in a single expression instead of declaring a variable. But for simplicity I used this route. Execute the flow. And below is the result of flow run.

start day of the month using Power Automate

As of writing this blog, today’s date is 29 day of March, 2021. Quite understandably, the expression result of the condition statement is false. But what is important here is the output result of startOfMonth expression.

You may also like the below posts.

Hope this helped!

Debajit Dutta
Business Solutions MVP