Example

A simple animation-fill-mode property example:

Laboratory

description & Usage

The animation-fill-mode property specifies a style for the animation property that does not run before or after it starts.

Informations

# Description
Default Value none
Inherited no
Animatable no
Version CSS3
JavaScript syntax object.style.animationFillMode="forwards"

Browser compatibility and Support

The numbers inserted in the browser fields indicate the version that supports the animation-fill-mode property.

# Chrome Edge Firefox Safari Opera
animation-fill-mode

Syntax

Values

Values Description
none The animation does not follow any values.
forwards The corresponding value activates the style specified by the last framekey for the animation.
backwards The corresponding value activates the style specified by the first framekey for the animation.
both Animation uses forward and then backward rules.
initial Adds this value to its default property.
inherit It inherits this value from its parent tag.

Related Pages

CSS tutorial: CSS animations

HTML DOM reference: animationFillMode property