web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Change Header colour i...
Power Apps
Suggested Answer

Change Header colour in Environment

(3) ShareShare
ReportReport
Posted on by 33
Is it possible to change the header color from the standard purple depending on which environment you are in , within  power platform?  I would like to have different ones for Dev/Prod/Test it just helps to make if obvious.  TIA
I have the same question (1)
  • vipuljain03 Profile Picture
    673 Super User 2026 Season 1 on at
    Approach-1:
    By using environment variables & Param, you can achieve this scenario.
     
    You can set the header color in the App.OnStart property and check the environment and set the header color based on Param value.
     
    Below is a sample code:
    Set(
        varHeaderColor,
        If(
            IsBlank(Param("HeaderColor")), // Check if Param is blank (i.e. running in editor)
            "#808080", // Default gray color for editor
            Param("HeaderColor")
        )
        // For Production:
        // EnvironmentVariable.HeaderColor
    );
     
    Approach-2:
    I change the App Name/Title based on environment. So if user open UAT app, it will show App_Name-UAT etc.
     
  • DBNL Profile Picture
    33 on at
    Thanks for  your response .  However I  don't think I explained myself properly. It's not the app header it's the actual environment header.  TIA
  • PowerDeveloperTP Profile Picture
    442 on at
    Hello,
     
    You will have to do it from Microsoft 365 Administration Page -> Customize the theme for your organization - Microsoft 365 admin | Microsoft Learn
     
    Thanks

    Like my answer? - Hit that Thumbs Up. Resolved the Issue? - Hit Accept as Solution.

    This helps others find solutions to future issues!
  • Suggested answer
    Ravi-Prajapati Profile Picture
    416 Moderator on at

    Yes! You can dynamically change the header color in Power Apps based on the environment (Dev, Test, Prod). Here’s how you can do it:


    Method 1: Using Environment() Function (Recommended)

    The Environment() function retrieves the current environment name, which you can use to set a different color for each environment.

    Steps:

    1. Go to App > OnStart and define a variable:

      Set(varEnv, Environment().Name);
    2. Set the Fill property of the header (or app background) to:

      Switch(
      varEnv,
      "Dev", RGBA(255, 165, 0, 1), // Orange for Dev
      "Test", RGBA(0, 123, 255, 1), // Blue for Test
      "Prod", RGBA(220, 20, 60, 1), // Red for Prod
      RGBA(128, 0, 128, 1) // Default Purple
      )
      • Change "Dev", "Test", and "Prod" to match your environment names.

    Method 2: Using a Custom Table (If You Need More Control)

    If Environment().Name doesn’t match your expectations, you can create a Settings Table in Dataverse with:

    • EnvironmentName (e.g., Dev, Test, Prod)
    • HeaderColor (e.g., #FFA500 for orange)

    Then, onappstart, use LookUp() to fetch the right color:

    Set(varHeaderColor, LookUp(Settings, EnvironmentName = Environment().Name, HeaderColor));

    Then set the header’s Fill property:

    ColorValue(varHeaderColor)
  • FV-17061134-0 Profile Picture
    2 on at
    The question is quite clear and evident. If you have multiple Power Platform Environments you want to make a difference for ALL content(not just specific apps) that it is clear to all users if they are in a DEV, Test, Acceptance or Production Environment.
    I have used and seen it before and I know for sure it is possible to change the color and even add text or change logo per Environment. 
    But I forgot where to set it. (that is how I end up on this site/question)

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 519 Most Valuable Professional

#2
11manish Profile Picture

11manish 489

#3
Haque Profile Picture

Haque 327

Last 30 days Overall leaderboard