Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.
Hello,
Asking for help creating a calendar visual in PBI that displays a whole year at a time. Wanting to be able to change the color of the day depending on a true or false value.
Something like this:
I tried some examples like this one https://medium.com/microsoft-power-bi/calendar-heatmap-visual-in-power-bi-a-macgyvered-approach-1796... but I couldn't get my visual to work like in the example.
Any help would be appreciated.
Thanks,
Tim
Solved! Go to Solution.
Try the approach in the attached pbix.
Hi @bigmac025
As we haven’t heard back from you, we wanted to kindly follow up to check if the suggestions provided by the community members for the issue worked. Please feel free to contact us if you have any further questions.
Thanks and regards
Hi @bigmac025
May I check if this issue has been resolved? If not, Please feel free to contact us if you have any further questions.
Thank you
Hi @bigmac025
I wanted to check if you had the opportunity to review the information provided. Please feel free to contact us if you have any further questions.
Thank you.
Try the approach in the attached pbix.
I recently published a blog about this. The pbix in there is a more polished version.
Thank you @danextian! This was perfect. I apologize for not responding earlier, I was on holiday.
- Create a calendar table in DAX with columns for date, weekday, week number, and a TRUE/FALSE flag.
- Use a matrix visual: rows = week number, columns = weekday name, values = day number.
- Apply conditional formatting to color days based on the TRUE/FALSE flag.
This gives you a full-year calendar view with dynamic coloring.
Create a Calendar Table
Calendar =
ADDCOLUMNS (
CALENDAR (DATE(2025,1,1), DATE(2025,12,31)),
"Year", YEAR([Date]),
"Month", FORMAT([Date], "MMMM"),
"MonthNum", MONTH([Date]),
"Day", DAY([Date]),
"Weekday", WEEKDAY([Date], 2), -- 2 = Monday start
"WeekdayName", FORMAT([Date], "DDD"),
"WeekNum", WEEKNUM([Date], 2),
"IsFlagged", [YourLogicHere] -- Replace with your TRUE/FALSE logic
)
Build the Matrix Visual
Use a matrix to simulate the calendar grid:
- Rows: WeekNum
- Columns: WeekdayName
- Values: Use a measure like this:
DayLabel =
IF (
SELECTEDVALUE('Calendar'[IsFlagged]),
FORMAT(SELECTEDVALUE('Calendar'[Day]), "00"),
BLANK()
)
Conditional Formatting
Apply color rules to highlight flagged days:
DayColor =
SWITCH (
TRUE(),
SELECTEDVALUE('Calendar'[IsFlagged]) = TRUE(), "#FF9999", // Red for flagged
"#FFFFFF" // White for normal
)
So how is OP exactly going to comparmentalize each month? Care to share a sample pbix?