CSS element element Selector

Complete CSS Reference Complete CSS Reference

Example

How to style <p> elements inside <div> elements:

div p
{
background-color:yellow;
}

Try it yourself »

Definition and Usage

Separate selectors with a white-space, to style elements inside elements.

The element element selector styles elements inside elements.


Browser Support

Internet Explorer Firefox Opera Google Chrome Safari

The element element selector is supported in all major browsers.


CSS Version

The element element selector was first introduced in:

CSS 1


Complete CSS Reference Complete CSS Reference