Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
Anonymous
Not applicable

JSON Theme Card Property for Background

Hello,

 

Does anyone knows how to set the card background default color and transparency in a new PowerBI Theme?

 

Thank you

1 ACCEPTED SOLUTION
v-yulgu-msft
Microsoft Employee
Microsoft Employee

Hi @Anonymous,

 

JSON them file provides "background" and "transparency" properties allows us to set background color and transparency for a specific visual. Please refer to the sample in this article.

 

Regards,

Yuliana Gu

Community Support Team _ Yuliana Gu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
v-yulgu-msft
Microsoft Employee
Microsoft Employee

Hi @Anonymous,

 

JSON them file provides "background" and "transparency" properties allows us to set background color and transparency for a specific visual. Please refer to the sample in this article.

 

Regards,

Yuliana Gu

Community Support Team _ Yuliana Gu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
Not applicable

I cannot make it work... can you show a sample snippet of the code for the card background and transparency please?


Thank you

@Anonymous here is an example that works for me

 

{
   "name": "Card-Background-Example",
   "background": "#ffffff",
   "foreground": "#000000",
   "dataColors": [
      "#8AD4EB",
      "#939498",
      "#C0504D",
      "#DB6D4B"
   ],
   "visualStyles": {
      "*": {
         "*": {
            "*": [
               {
                  "fontSize": 12,
                  "fontFamily": "Calibri",
                  "color": {
                     "solid": {}
                  }
               }
            ],
            "general": [
               {
                  "responsive": true
               }
            ]
         }
      },
      "card": {
         "*": {
            "background": [
               {
                  "show": true,
                  "color": {
                     "solid": {
                        "color": "#8AD4EB"
                     }
                  },
                  "transparency": 0
               }
            ],
            "labels": [
               {
                  "show": true,
                  "color": {
                     "solid": {
                        "color": "#ffffff"
                     }
                  },
                  "fontSize": 14,
                  "fontFamily": "Calibri"
               }
            ]
         }
      }
   }
}

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors
Top Kudoed Authors