Cubic Bezier Generator for CSS Animations
A cubic bezier generator creates a CSS timing function that maps elapsed time to animation progress. Choose a preset above, drag its two handles, and scrub or play the preview. Copy the result into a transition, a CSS animation, or a Web Animations API call.
Start with a motion you can compare
Choose ease-out to test a change that moves quickly at the start and settles near the target. Open Advanced settings and add a comparison curve. Select linear for one of the curves as a reference. The preview uses one lane per curve and the graph uses dashed labeled lines for comparisons.
Keep the same duration for the comparison. Start the preview again with Replay or set the time slider to zero. Try translation first because travel distance makes early and late changes easy to see. Switch to rotation, scale, or opacity to see how the same timing affects another property.
If you already have a CSS value, paste the function and apply it. Enter four comma-separated numbers in cubic-bezier parentheses. The two x controls must be between zero and one. This workspace accepts y from minus ten through ten. Plain decimals and CSS scientific notation are accepted. A complete declaration such as transition-timing-function includes other syntax, so paste only the function value.
Read elapsed time and progress on the graph
The horizontal coordinate is the fraction of the active duration that has elapsed. The vertical coordinate is the output fraction for interpolating a property. The curve begins at (0, 0) and ends at (1, 1). The two interior handles are x1 and y1, then x2 and y2. They steer the curve while the endpoints stay fixed.
To read progress halfway through the duration, begin at x = 0.5 and go vertically until you meet the curve. The implementation finds a parameter t for which the cubic x coordinate equals that time. It tries a bounded Newton update and uses bisection when the slope or candidate step is unsuitable. It then evaluates y at the resulting t.
The internal curve parameter t and elapsed fraction x usually differ. The slider is labeled Time progress and the two values appear separately in the workspace. For linear with controls (0, 0) and (1, 1), the result equals elapsed time even though the cubic parameter usually differs from the time fraction. This makes linear a simple check of the inversion.
Design an overshoot and inspect the property
Paste cubic-bezier(0.3, 0, 0.65, 1.45). The second y control lies above one and the graph fits all handles. Move the time slider near the end and observe progress above one before it returns to the target. In translation, that portion travels beyond the final position in the direction of motion, then reverses briefly.
A negative y value can pull progress below zero and give a short anticipation movement. How far you see depends on the whole curve and on what the property allows. Opacity in the preview is clamped to its valid zero-to-one range. That can flatten the part above one into a period of full visibility.
One cubic timing function shapes acceleration and settling over a fixed duration. A multi-bounce effect with distinct contacts can use several keyframes or a timing function designed for that sequence. For a control that can be interrupted and retargeted, test the behavior in the product as the user interacts.
Copy timing settings into a project
The top Copy button copies the function. In the timing function panel, the transition option adds the selected property, duration and delay. The animation option outputs timing declarations for use with your keyframes. The Web Animations API option includes sample keyframes with the chosen property. Set the start and end values for your element.
Delay is elapsed milliseconds before the preview enters the active interval. It leaves the control points and timing function unchanged. Duration determines how fast time moves along the same x axis. Use Replay to test the entire delay and active interval. Play can continue from a point set with the slider or from a paused preview.
When checking a timing function someone else sent you, keep a linear comparison visible and stop at the same elapsed fraction in both lanes. This makes it easier to tell whether the timing difference comes from the curve or from a separate choice of duration.
Test the easing in your interface with its actual travel distance. A translate across a small button and a translate across a full viewport can feel different with the same function. For users who request reduced motion, consider a smaller change, an instant state update, or an alternative based on opacity. The workspace honors that preference by allowing manual scrubbing while skipping automatic playback.
Frequently asked questions
Why does an x value outside the allowed range fail?
CSS cubic-bezier timing functions constrain both x controls to [0, 1] so the curve can map time to progress. The geometry cubic tool allows free control coordinates for drawing paths.
Is ease-in-out the same as ease?
These are separate CSS presets. Ease uses controls (0.25, 0.1) and (0.25, 1). Ease-in-out uses (0.42, 0) and (0.58, 1). Compare both over the same duration to isolate the timing difference.
Does a progress of 0.8 mean the animation is 80 percent complete in time?
It means the interpolated value has traveled 80 percent of the value range for ordinary linear property interpolation. The corresponding elapsed time comes from the x value and may differ.
Further reading · MDN’s CSS cubic-bezier reference