html set background color of div code example Example: turn a div green div { background-color: green; }