Black Friday: 50% off all products for the first 50 customers. Only 10 left. Use code
40/50 claimed
See pricing →

Theming

Components never hard-code brand colours. They use Quasar's colour names, such as color="primary", text-primary and bg-dark, so changing the colours once restyles every Component you have copied.

Set your brand colours

Quasar reads its colours from Sass variables.

Nuxt with nuxt-quasar-ui: create assets/quasar-variables.scss and point the module at it.

@forward "quasar/src/css/variables.sass" with (
  $primary: #0ea5e9,
  $secondary: #26a69a,
  $accent: #9c27b0,
  $dark: #0f172a,
  $dark-page: #121212,
  $positive: #21ba45,
  $negative: #c10015,
  $info: #31ccec,
  $warning: #f2c037
);
export default defineNuxtConfig({
  quasar: {
    sassVariables: "~/assets/quasar-variables.scss",
  },
});

nuxt-quasar-ui needs the sass package for this: npm install -D sass.

Quasar CLI: edit src/css/quasar.variables.scss, which the project already has:

$primary   : #0ea5e9;
$secondary : #26a69a;
$accent    : #9c27b0;
$dark      : #0f172a;
$dark-page : #121212;

Use the Theme Builder

The free Quasar Theme Builder starts from one of 12 presets. You can change each brand colour and the neutral scale (from a Tailwind palette, by shade, or with OKLCH curves), the fonts, the icon set, the radius and the component defaults, and preview them on real Components in light and dark mode. It also gives you a share link for the theme.

Export it and pick your project type.

Nuxt with nuxt-quasar-ui:

  • assets/css/quasar-theme.css: the colour scales as CSS variables, light and dark tokens, fonts, radius, and the styles that point Quasar's components at them;
  • nuxt.config.ts: the quasar keys to merge into your config (icon set, extras, dark mode and component defaults);
  • assets/quasar.variables.scss: the light-mode colours, radius and font as Sass variables.

Quasar CLI:

  • src/css/quasar-theme.css: the same stylesheet;
  • quasar.config.js: the keys to merge into your config;
  • src/boot/theme-defaults.js: a boot file that sets the component defaults;
  • src/css/quasar.variables.scss: the Sass variables.

The CSS file owns dark mode, so keep dark: "auto" (or your own toggle) in the Quasar config.

Fonts

Components inherit the page font. Set it once on body. The QuasarUI previews use Inter.