Pinatool

CSS Cubic Bézier Generator

Design custom CSS easing curves with interactive control handles. Compare how your curve accelerates and settles in a live motion race, test durations, and export production-ready CSS with an accessible reduced-motion fallback.

Standard & Expressive Easing Presets

Select a preset to load control handles and timing

Interactive Bézier Curve Graph

Drag handles P1 and P2. Horizontal is Time (0 to 1); Vertical is Progress.

P1P2
(0, 0)(1, 1)
Time: 0% → 100%Y can overshoot below 0 or above 1 for bounces

Live Motion Comparison Arena

Compare how your curve accelerates and settles compared to standard timing

Your Curve (cubic-bezier(0.42, 0, 0.58, 1))1.2s
★
Ease In Out1.2s
E
Linear1.2s
L

Exact Control Point Values

P1 shapes the start; P2 shapes the landing. CSS limits X to 0–1; Y can overshoot.

1.2s
CSS Function Value
cubic-bezier(0.42, 0, 0.58, 1)

Generated Production CSS

Works directly with CSS transitions, CSS @keyframes, and includes a reduced-motion fallback.

.animated-element {
  transition: transform 1.2s cubic-bezier(0.42, 0, 0.58, 1);
  animation: slide-in 1.2s cubic-bezier(0.42, 0, 0.58, 1);
}

@media (prefers-reduced-motion: reduce) {
  .animated-element {
    transition: none;
    animation: none;
  }
}

How It Works

1

Pick a Curve Preset

Choose from standard curves like Ease In Out or expressive motion styles like Overshoot, Anticipate, or Snappy Spring as your starting point.

2

Drag Handles P1 and P2

Drag control points directly on the graph or enter exact coordinate numbers. Watch the live motion race comparison update in real time.

3

Copy Production CSS

Copy the standalone cubic-bezier(...) string, full transition rules, or download a standalone stylesheet with a reduced-motion fallback.

CSS Cubic Bézier Generator Key Features

Draggable Control Handles

Smooth SVG pointer interaction with tangent guide lines and coordinate clamping built directly into the canvas.

Live Motion Race Arena

Test how your custom easing compares side-by-side against linear and ease-in-out baselines at variable durations.

Accessible Fallback Built-in

Every code export automatically includes a prefers-reduced-motion media query to respect user accessibility preferences.

Frequently Asked Questions

What is a cubic Bézier curve in CSS?

A cubic Bézier curve defines the acceleration and deceleration rate of a CSS transition or animation over time. It is represented by four points: fixed start (0, 0), fixed end (1, 1), and two draggable control points P1(x1, y1) and P2(x2, y2) that dictate the curve trajectory.

Why do X coordinates have to stay between 0 and 1?

In CSS animation curves, the horizontal X axis strictly represents elapsed time from 0% to 100%. Because time cannot flow backwards or become ambiguous, both control-point X values are clamped between 0 and 1.

Can Y coordinates go below 0 or above 1?

Yes. Unlike the X axis, the vertical Y axis represents animation progress or position. Allowing Y values below 0 creates anticipation (pulling backward before moving forward), while Y values above 1 produce overshoot and spring-like bounce effects.

Can I use cubic-bezier() with both transitions and keyframe animations?

Yes. The cubic-bezier() function serves as an animation-timing-function or transition-timing-function identically in both contexts, controlling how values interpolate between frames or style states.

How do standard CSS keywords like ease and ease-in-out relate to cubic-bezier?

Built-in CSS keywords are aliases for specific cubic-bezier formulas: "ease" is cubic-bezier(0.25, 0.1, 0.25, 1), "ease-in" is cubic-bezier(0.42, 0, 1, 1), "ease-out" is cubic-bezier(0, 0, 0.58, 1), and "ease-in-out" is cubic-bezier(0.42, 0, 0.58, 1).