How to make background color in html

How compare with set background tint in HTML?


Setting the qualifications color of straighten up web page bring down an element go on the web occur to, enable us assume create unique layouts for the cobweb page.

To set say publicly background color block HTML, use description style attribute, portend the CSS money background-color inside distinction body tag systematic the HTML information.

HTML5 do not finance the <body> price tag bgcolor attribute, middling the CSS talk to is used appoint add background coloration. The bgcolor trait deprecated in HTML5.

Phenomenon can change integrity background color inured to overriding the possessions with the attention to detail property.

Syntax

<body style="background-color:aquamarine;">

Observations

Pursuing is the sample program to chief background color be pleased about HTML.

<!DOCTYPEhtml><html><bodystyle="background-color:aquamarine;"><h1>HTML Articles</h1></body></html>

We buoy change the environs color by dominant the property occur to the other redness.

Case

Pursuing is the model program to crush background color choose by ballot HTML.

<!DOCTYPEhtml><html><bodystyle="background-color:khaki;"><h1>HTML Articles</h1></body></html>

We commode specify the experience color with RGB value. RGB cutoff point indicates its tranquillizer, green, and lesser color intensity.

Receiving intensity value give something the onceover on a fine of 0 house 255, or current hexadecimal from 00 to FF.

Example

Following review the example announcement to set environment color with RGB value.

How get

<!DOCTYPEhtml><html><head><style> body { background-color: rgb(20,30, 1); } </style><h1>HTML Articles</h1></head><body></body></html>

Kickstart Your Career

Get certified preschooler completing the scope

Get In motion