set bg color css code example Example 1: css background color body { background-color: green; } Example 2: css set background color body { background-color: red; }