Best approach to customize colors in ERPNext v16?

Hi all,
I’m running ERPNext v16 and want to customize the color scheme to match our brand (primary color, sidebar, buttons) for both Desk and the website portal.
Options I’ve looked at: custom app CSS, Website Theme Doctype, CSS variable overrides, and editing source + bench build.
Questions:

  1. What’s the recommended/best practice approach in v16?
  2. Is overriding CSS variables the cleanest way, or is a custom theme better?
  3. How do I make changes upgrade-safe (survive bench migrate/build)?
  4. Any v16-specific gotchas (Frappe UI, dark mode, RTL)?
    Thanks in advance!

Hi,

I would recommend creating a new theme that matches your brand identity instead of modifying the core styles. This approach is cleaner, easier to maintain, and more upgrade-safe, as your customization’s remain separate from the frameworks source code.

Thank you!