// troubleshooting guide · datawrapper

Datawrapper Embed Dark Background or Wrong Colors

Status
Workaround available
platforms:
Web
updated:
November 16, 2026
reports:
2
Method
how we research
Share

RUNBOOK · datawrapper/dark-mode-embed3 FIXES

// quick answer

Automatic dark mode follows the reader's system setting, so the chart can turn dark on a light site. Turn it off in the Layout tab, or force a mode with ?dark=false / ?dark=true.

Most likely fix: Turn automatic dark mode off

How to fix it

// try these in order, the most common fix is first

  1. FIX 1Turn automatic dark mode off

    1. 01Open step 3: Visualize > Layout
    2. 02Switch off automatic dark mode
    3. 03Republish
    Did this fix it?
  2. FIX 2Force light or dark per embed

    1. 01Iframe: add ?dark=false (or ?dark=true) to the chart URL
    2. 02Script embed: add data-dark="false" (or "true") to the script tag
    3. 03Sites with their own toggle can switch the parameter to match
    Did this fix it?
  3. FIX 3Fix mismatched backgrounds

    1. 01Set color-scheme: dark in CSS on the iframe or its container when the site is dark
    2. 02Use .hide-in-dark / .hide-in-light classes for inline-styled text
    3. 03Turn on the option to keep the same colors in dark mode if needed
    Did this fix it?

Symptoms

The embedded chart shows a dark background on a light page, a solid background that doesn't match the site, or colors that look wrong in dark mode.

Why it happens

  • C-01Automatic dark mode enabled while the website itself has no dark mode
  • C-02Browser adds a solid background for legibility
  • C-03Inline HTML styles not converted for dark mode
  • C-04Custom theme dark mode settings

// this guide also covers

  • datawrapper dark mode
  • datawrapper chart black background
  • datawrapper embed background color

Still not working?

If Datawrapper keeps failing, you're not alone. See every Datawrapper problem users report or the alternatives people switch to.

Have an app idea? Our small team builds any software: web and mobile apps, games, desktop, AI tools. Price agreed together.

Talk to us

Watch Datawrapper Get an email when its price changes, it has an outage, or we publish a new fix. No spam.

Fixed it? Share this guide

The same problem in other apps

All ai & editing tools not working guides →

Other Datawrapper errors

All 12 Datawrapper errors and fixes →