CSS Property Groups CSS Reference

Alphabetical List

The "CSS" column indicates in which CSS version the property is defined (CSS1, CSS2, or CSS3).

Animation Properties

@keyframesSpecifies the animation3
animationA shorthand property for all the animation properties below, except the animation-play-state property3
animation-nameSpecifies a name for the @keyframes animation3
animation-durationSpecifies how many seconds or milliseconds an animation takes to complete one cycle3
animation-timing-functionSpecifies the speed curve of the animation3
animation-delaySpecifies when the animation will start3
animation-iteration-countSpecifies the number of times an animation should be played3
animation-directionSpecifies whether or not the animation should play in reverse on alternate cycles3
animation-play-stateSpecifies whether the animation is running or paused3

Background Properties

backgroundSets all the background properties in one declaration1
background-attachmentSets whether a background image is fixed or scrolls with the rest of the page1
background-colorSets the background color of an element1
background-imageSets the background image for an element1
background-positionSets the starting position of a background image1
background-repeatSets how a background image will be repeated1
background-clipSpecifies the painting area of the background3
background-originSpecifies the positioning area of the background images3
background-sizeSpecifies the size of the background images3

Border and Outline Properties

borderSets all the border properties in one declaration1
border-bottomSets all the bottom border properties in one declaration1
border-bottom-colorSets the color of the bottom border
border-bottom-styleSets the style of the bottom border1
border-bottom-widthSets the width of the bottom border1
border-colorSets the color of the four borders1
border-leftSets all the left border properties in one declaration1
border-left-colorSets the color of the left border1
border-left-styleSets the style of the left border1
border-left-widthSets the width of the left border1
border-rightSets all the right border properties in one declaration1
border-right-colorSets the color of the right border1
border-right-styleSets the style of the right border1
border-right-widthSets the width of the right border1
border-styleSets the style of the four borders1
border-topSets all the top border properties in one declaration1
border-top-colorSets the color of the top border1
border-top-styleSets the style of the top border1
border-top-widthSets the width of the top border1
border-widthSets the width of the four borders1
outlineSets all the outline properties in one declaration2
outline-colorSets the color of an outline2
outline-styleSets the style of an outline2
outline-widthSets the width of an outline2
border-bottom-left-radiusDefines the shape of the border of the bottom-left corner3
border-bottom-right-radiusDefines the shape of the border of the bottom-right corner3
border-imageA shorthand property for setting all the border-image-* properties3
border-image-outsetSpecifies the amount by which the border image area extends beyond the border box3
border-image-repeatSpecifies whether the image-border should be repeated, rounded or stretched3
border-image-sliceSpecifies the inward offsets of the image-border3
border-image-sourceSpecifies an image to be used as a border3
border-image-widthSpecifies the widths of the image-border3
border-radiusA shorthand property for setting all the four border-*-radius properties3
border-top-left-radiusDefines the shape of the border of the top-left corner3
border-top-right-radiusDefines the shape of the border of the top-right corner3
box-decoration-break 3
box-shadowAttaches one or more drop-shadows to the box3

Box Properties

overflow-xSpecifies whether or not to clip the left/right edges of the content, if it overflows the element's content area3
overflow-ySpecifies whether or not to clip the top/bottom edges of the content, if it overflows the element's content area3
overflow-styleSpecifies the preferred scrolling method for elements that overflow3
rotationRotates an element around a given point defined by the rotation-point property3
rotation-pointDefines a point as an offset from the top left border edge3

Color Properties

color-profilePermits the specification of a source color profile other than the default3
opacitySets the opacity level for an element3
rendering-intentPermits the specification of a color profile rendering intent other than the default3

Content for Paged Media Properties

bookmark-labelSpecifies the label of the bookmark3
bookmark-levelSpecifies the level of the bookmark3
bookmark-targetSpecifies the target of the bookmark link3
float-offsetPushes floated elements in the opposite direction of the where they have been floated with float3
hyphenate-afterSpecifies the minimum number of characters in a hyphenated word after the hyphenation character3
hyphenate-beforeSpecifies the minimum number of characters in a hyphenated word before the hyphenation character3
hyphenate-characterSpecifies a string that is shown when a hyphenate-break occurs3
hyphenate-linesIndicates the maximum number of successive hyphenated lines in an element3
hyphenate-resourceSpecifies a comma-separated list of external resources that can help the browser determine hyphenation points3
hyphensSets how to split words to improve the layout of paragraphs3
image-resolutionSpecifies the correct resolution of images3
marksAdds crop and/or cross marks to the document3
string-set 3

Dimension Properties

heightSets the height of an element1
max-heightSets the maximum height of an element2
max-widthSets the maximum width of an element2
min-heightSets the minimum height of an element2
min-widthSets the minimum width of an element2
widthSets the width of an element1

Flexible Box Properties

box-alignSpecifies how to align the child elements of a box3
box-directionSpecifies in which direction the children of a box are displayed3
box-flexSpecifies whether the children of a box is flexible or inflexible in size3
box-flex-groupAssigns flexible elements to flex groups3
box-linesSpecifies whether columns will go onto a new line whenever it runs out of space in the parent box3
box-ordinal-groupSpecifies the display order of the child elements of a box3
box-orientSpecifies whether the children of a box should be laid out horizontally or vertically3
box-packSpecifies the horizontal position in horizontal boxes and the vertical position in vertical boxes3

Font Properties

fontSets all the font properties in one declaration1
font-familySpecifies the font family for text1
font-sizeSpecifies the font size of text1
font-styleSpecifies the font style for text1
font-variantSpecifies whether or not a text should be displayed in a small-caps font1
font-weightSpecifies the weight of a font1
@font-faceA rule that allows websites to download and use fonts other than the "web-safe" fonts3
font-size-adjustPreserves the readability of text when font fallback occurs3
font-stretchSelects a normal, condensed, or expanded face from a font family3

Generated Content Properties

contentUsed with the :before and :after pseudo-elements, to insert generated content2
counter-incrementIncrements one or more counters2
counter-resetCreates or resets one or more counters2
quotesSets the type of quotation marks for embedded quotations2
cropAllows a replaced element to be just a rectangular area of an object, instead of the whole object3
move-toCauses an element to be removed from the flow and reinserted at a later point in the document3
page-policyDetermines which page-based occurance of a given element is applied to a counter or string value3

Grid Properties

grid-columnsSpecifies the width of each column in a grid3
grid-rowsSpecifies the height of each column in a grid3

Hyperlink Properties

targetA shorthand property for setting the target-name, target-new, and target-position properties3
target-nameSpecifies where to open links (target destination)3
target-newSpecifies whether new destination links should open in a new window or in a new tab of an existing window3
target-positionSpecifies where new destination links should be placed3

Linebox Properties

alignment-adjustAllows more precise alignment of elements3
alignment-baselineSpecifies how an inline-level element is aligned with respect to its parent3
baseline-shiftAllows repositioning of the dominant-baseline relative to the dominant-baseline3
dominant-baselineSpecifies a scaled-baseline-table3
drop-initial-after-adjustSets the alignment point of the drop initial for the primary connection point3
drop-initial-after-alignSets which alignment line within the initial line box is used at the primary connection point with the initial letter box3
drop-initial-before-adjustSets the alignment point of the drop initial for the secondary connection point3
drop-initial-before-alignSets which alignment line within the initial line box is used at the secondary connection point with the initial letter box3
drop-initial-sizeControls the partial sinking of the initial letter3
drop-initial-valueActivates a drop-initial effect
inline-box-alignSets which line of a multi-line inline block align with the previous and next inline elements within a line3
line-stackingA shorthand property for setting the line-stacking-strategy, line-stacking-ruby, and line-stacking-shift properties3
line-stacking-rubySets the line stacking method for block elements containing ruby annotation elements3
line-stacking-shiftSets the line stacking method for block elements containing elements with base-shift3
line-stacking-strategySets the line stacking strategy for stacked line boxes within a containing block element3
text-heightSets the block-progression dimension of the text content area of an inline box3

List Properties

list-styleSets all the properties for a list in one declaration1
list-style-imageSpecifies an image as the list-item marker1
list-style-positionSpecifies if the list-item markers should appear inside or outside the content flow1
list-style-typeSpecifies the type of list-item marker1

Margin Properties

marginSets all the margin properties in one declaration1
margin-bottomSets the bottom margin of an element1
margin-leftSets the left margin of an element1
margin-rightSets the right margin of an element1
margin-topSets the top margin of an element1

Marquee Properties

marquee-directionSets the direction of the moving content3
marquee-play-countSets how many times the content move3
marquee-speedSets how fast the content scrolls3
marquee-styleSets the style of the moving content3

Multi-column Properties

column-countSpecifies the number of columns an element should be divided into3
column-fillSpecifies how to fill columns3
column-gapSpecifies the gap between the columns3
column-ruleA shorthand property for setting all the column-rule-* properties3
column-rule-colorSpecifies the color of the rule between columns3
column-rule-styleSpecifies the style of the rule between columns3
column-rule-widthSpecifies the width of the rule between columns3
column-spanSpecifies how many columns an element should span across3
column-widthSpecifies the width of the columns3
columnsA shorthand property for setting column-width and column-count3

Padding Properties

paddingSets all the padding properties in one declaration1
padding-bottomSets the bottom padding of an element1
padding-leftSets the left padding of an element1
padding-rightSets the right padding of an element1
padding-topSets the top padding of an element1

Paged Media Properties

fitGives a hint for how to scale a replaced element if neither its width nor its height property is auto3
fit-positionDetermines the alignment of the object inside the box3
image-orientationSpecifies a rotation in the right or clockwise direction that a user agent applies to an image3
pageSpecifies a particular type of page where an element SHOULD be displayed3
sizeSpecifies the size and orientation of the containing box for page content3

Positioning Properties

bottomSpecifies the bottom position of a positioned element2
clearSpecifies which sides of an element where other floating elements are not allowed1
clipClips an absolutely positioned element2
clip-pathThe clip-path property prevents a portion of an element from drawing by defining a clipping region.2
cursorSpecifies the type of cursor to be displayed2
displaySpecifies how a certain HTML element should be displayed1
floatSpecifies whether or not a box should float1
leftSpecifies the left position of a positioned element2
Specifies what happens if content overflows an element's box2
positionSpecifies the type of positioning method used for an element (static, relative, absolute or fixed)2
rightSpecifies the right position of a positioned element2
topSpecifies the top position of a positioned element2
visibilitySpecifies whether or not an element is visible2
z-indexSets the stack order of a positioned element2

Print Properties

orphansSets the minimum number of lines that must be left at the bottom of a page when a page break occurs inside an element2
page-break-afterSets the page-breaking behavior after an element2
page-break-beforeSets the page-breaking behavior before an element2
page-break-insideSets the page-breaking behavior inside an element2
widowsSets the minimum number of lines that must be left at the top of a page when a page break occurs inside an element2

Ruby Properties

ruby-alignControls the text alignment of the ruby text and ruby base contents relative to each other3
ruby-overhangDetermines whether, and on which side, ruby text is allowed to partially overhang any adjacent text in addition to its own base, when the ruby text is wider than the ruby base3
ruby-positionControls the position of the ruby text with respect to its base3

Speech Properties

markA shorthand property for setting the mark-before and mark-after properties3
mark-afterAllows named markers to be attached to the audio stream3
mark-beforeAllows named markers to be attached to the audio stream3
phonemesSpecifies a phonetic pronunciation for the text contained by the corresponding element3
restA shorthand property for setting the rest-before and rest-after properties3
rest-afterSpecifies a rest or prosodic boundary to be observed after speaking an element's content3
rest-beforeSpecifies a rest or prosodic boundary to be observed before speaking an element's content3
voice-balanceSpecifies the balance between left and right channels3
voice-durationSpecifies how long it should take to render the selected element's content3
voice-pitchSpecifies the average pitch (a frequency) of the speaking voice3
voice-rangeSpecifies variation in average pitch3
voice-rateControls the speaking rate3
voice-stressIndicates the strength of emphasis to be applied3
voice-volumeRefers to the amplitude of the waveform output by the speech synthesises3

Table Properties

border-collapseSpecifies whether or not table borders should be collapsed2
border-spacingSpecifies the distance between the borders of adjacent cells2
caption-sideSpecifies the placement of a table caption2
empty-cellsSpecifies whether or not to display borders and background on empty cells in a table2
table-layoutSets the layout algorithm to be used for a table2

Text Properties

colorSets the color of text1
directionSpecifies the text direction/writing direction2
letter-spacingIncreases or decreases the space between characters in a text1
line-heightSets the line height1
text-alignSpecifies the horizontal alignment of text1
text-decorationSpecifies the decoration added to text1
text-indentSpecifies the indentation of the first line in a text-block1
text-transformControls the capitalization of text1
unicode-bidiUsed together with the direction property to set or return whether the text should be overridden to support multiple languages in the same document2
vertical-alignSets the vertical alignment of an element1
white-spaceSpecifies how white-space inside an element is handled1
word-spacingIncreases or decreases the space between words in a text1
hanging-punctuationSpecifies whether a punctuation character may be placed outside the line box3
punctuation-trimSpecifies whether a punctuation character should be trimmed3
text-align-lastDescribes how the last line of a block or a line right before a forced line break is aligned when text-align is "justify"3
text-justifySpecifies the justification method used when text-align is "justify"3
text-outlineSpecifies a text outline3
text-overflowSpecifies what should happen when text overflows the containing element3
text-shadowAdds shadow to text3
text-wrapSpecifies line breaking rules for text3
word-breakSpecifies line breaking rules for non-CJK scripts3
word-wrapAllows long, unbreakable words to be broken and wrap to the next line3

2D/3D Transform Properties

transformApplies a 2D or 3D transformation to an element3
transform-originAllows you to change the position on transformed elements3
transform-styleSpecifies how nested elements are rendered in 3D space3
perspectiveSpecifies the perspective on how 3D elements are viewed3
perspective-originSpecifies the bottom position of 3D elements3
backface-visibilityDefines whether or not an element should be visible when not facing the screen3

Transition Properties

transitionA shorthand property for setting the four transition properties3
transition-propertySpecifies the name of the CSS property the transition effect is for3
transition-durationSpecifies how many seconds or milliseconds a transition effect takes to complete3
transition-timing-functionSpecifies the speed curve of the transition effect3
transition-delaySpecifies when the transition effect will start3

User-interface Properties

appearanceAllows you to make an element look like a standard user interface element3
box-sizingAllows you to define certain elements to fit an area in a certain way3
iconProvides the author the ability to style an element with an iconic equivalent3
nav-downSpecifies where to navigate when using the arrow-down navigation key3
nav-indexSpecifies the tabbing order for an element3
nav-leftSpecifies where to navigate when using the arrow-left navigation key3
nav-rightSpecifies where to navigate when using the arrow-right navigation key3
nav-upSpecifies where to navigate when using the arrow-up navigation key3
outline-offsetOffsets an outline, and draws it beyond the border edge3
resizeSpecifies whether or not an element is resizable by the user3

CSS Selectors

:activeSelects the active link1
:afterInsert content after every <p> element2
:beforeInsert content before the content of every <p> element2
:checkedSelects every checked <input> element3
:disabledSelects every disabled <input> element3
:emptySelects every <p> element that has no children (including text nodes)3
:targetSelects the current active #news element (clicked on a URL containing that anchor name)3
:enabledSelects every enabled <input> element3
:first-childSelects every <p> element that is the first child of its parent2
:first-letterSelects the first letter of every <p> element1
:first-lineSelects the first line of every <p> element1
:first-of-typeSelects every <p> element that is the first <p> element of its parent3
:focusSelects the input element which has focus2
:hoverSelects links on mouse over1
:langSelects every <p> element with a lang attribute equal to "it" (Italian)2
:last-childSelects every <p> element that is the last child of its parent3
:last-of-typeSelects every <p> element that is the last <p> element of its parent3
:linkSelects all unvisited links1
:not()Selects every element that is not a <p> element3
:nth-child(n)Selects every <p> element that is the second child of its parent3
:nth-last-child(n)Selects every <p> element that is the second child of its parent, counting from the last child3
:nth-last-of-type(n)Selects every <p> element that is the second <p> element of its parent, counting from the last child3
:nth-of-type(n)Selects every <p> element that is the second <p> element of its parent3
:only-childSelects every <p> element that is the only child of its parent3
:only-of-typeSelects every <p> element that is the only <p> element of its parent3
:rootSelects the document's root element3
::selectionSelects the portion of an element that is selected by a user3
:visitedSelects all visited links1

Other Properties

align-content Aligns a flex container's lines within the flex container when there is extra space in the cross-axis, similar to how justify-content aligns individual items within the main-axis.NA
align-items Sets the default alignment in the cross axis for all of the flex container's items, including anonymous flex items, similarly to how justify-content aligns items along the main axis.NA
align-self Allows the default alignment to be overridden for individual flex items.NA
animation-fill-modeDefines what values are applied by the animation outside the time it is executing (before and after the animation).NA
break-afterThe CSS break-after property allows you to force a break on multi-column layouts.NA
break-before Control page/column/region breaks that fall above a block of contentNA
break-insideControl page/column/region breaks that fall within a block of contentNA
filterSpecifies the filter or collection of filters applied to the object.NA
flexThe flex CSS property specifies the ability of a flex item to alter its dimensions to fill the available space. flex is a shorthand property comprised of the flex-grow, flex-shrink, and flex-basis properties.NA
flex-basisThe flex-basis CSS property describes the initial main size of the flex item before any free space is distributed according to the flex factors described in the flex property (flex-grow and flex-shrink).NA
flex-directionThe flex-direction CSS property describes how flex items are placed in the flex container, by setting the direction of the flex container's main axis.NA
flex-flowThe flex-flow CSS property defines the flex container's main and cross axis. It is a shorthand property for the flex-direction and flex-wrap properties.NA
flex-growThe flex-grow CSS property specifies how much a flex item will enlarge with respect to the other items in the flex container to fill an expanded container.NA
flex-shrinkThe flex-shrink CSS property specifies how much a flex item will be reduced with respect to the other items in the flex container to fit within a reduced container.NA
flex-wrapThe flex-wrap property controls whether the flex container is single-line or multi-line, and the direction of the cross-axis, which determines the direction in which new lines are stacked.NA
font-feature-settings The font-feature-settings property gets or sets one or more values that specify glyph substitution (special font characters such as ligatures and figures) and positioning in fonts that include OpenType layout features.NA
font-kerningThe font-kerning property allows contextual adjustment of inter-glyph spacing, i.e. the spaces between the characters in text. This property controls metric kerning - that utilizes adjustment data contained in the font. Optical Kerning is not supported as yet.3
font-language-override The 'font-language-override' property allows authors to explicitly specify the language system of the font, overriding the language system implied by the content language.3
font-synthesis This value specifies whether the user agent is allowed to synthesize bold or oblique font faces when a font family lacks bold or italic faces.3
font-variant-alternates Fonts can provide alternate glyphs in addition to default glyph for a character. This property provides control over the selection of these alternate glyphs.3
hyphens Specifies whether or not words in a sentence can be split by the use of a manual or automatic hyphenation mechanism.NA
image-renderingSpecifies the rendering mode for scaled images.NA
ime-modeSpecifies the state of an Input Method Editor (IME) for user text entry fields. IME allows users to enter and edit Chinese, Japanese, and Korean characters.NA
justify-content The justify-content property aligns flex items along the main axis of the current line of the flex container, similarly to how align-items aligns items in the cross axis.NA
marksThe "marks" property adds crop and/or cross marks to the presentation of the document.NA
mask Shorthand property for other mask- properties.NA
mask-type Defines whether the content of the element is treated as as luminance mask or an alpha mask.NA
order The order property controls the order in which flex items appear within their flex container, by assigning them to ordinal groups.NA
orphansThe orphans CSS property refers to the minimum number of lines in a block container that must be left at the bottom of the old page.NA
pointer-events The pointer-events property allows you to control whether an element can be the target for the pointing device (e.g, mouse, pen) events.NA
tab-size The tab-size CSS property is used to customise the width of a tab (U+0009) character.NA
text-combine-horizontalThis property specifies the combination of multiple characters into the space of a single character.3
text-decoration-line Sets what kind of line decorations are added to an element, such as underlines, overlines, etc.NA
text-orientationThis property specifies the orientation of text within a line.3
text-rendering The text-rendering CSS property provides information to the browser about how to optimize when rendering text. Options are: legibility, speed or geometric precision.NA
touch-action Determines whether touch input may trigger default behavior supplied by the user agent, such as panning or zooming.3
unicode-range unicode-range allows you to set a specific range of characters to be downloaded from a font (embedded using @font-face) and made available for use on the current page.NA
@viewportSpecifies properties that describe the viewport.2
widowsDefines the minimum number of lines that can appear in the beginning of a new page.NA
writing-mode writing-mode specifies if lines of text are laid out horizontally or vertically, and the direction which lines of text and blocks progress.NA

Relative articles