Calculated fields

Looker Studio calculated field – Remaining number of days until the end of the month

The Looker Studio (ex Google Data Studio) calculated field below returns the remaining number of days until the end of the month of a specific date.


  • Explanations of the formula step by step
    1. Create a date (line 2) using
      – the year of the date,
      – the month after the month of the date,
      – 0 as day to get the day just before the first day of the month
    2. Calculate the difference between the result of the 1st step and your date dimension
  • Input
    • Any date dimension with date type
  • Output
    • The remaining number of days until the end of the month of the date
  • Used functions

Remaining days until the end of the month
DATE_DIFF(
   DATE(YEAR(Date), MONTH(Date)+1, 0 )
   ,
   Date
)