Unit Vector Calculator
Find the unit vector (normalized direction) of any 2D or 3D vector by dividing each component by its magnitude.
How it works
- 1Enter the x, y (and optionally z) components of your vector and choose 2D or 3D mode.
- 2The calculator computes the Euclidean magnitude |v| = √(x² + y² + z²), then divides each component by |v| to produce v̂.
- 3The resulting unit vector always has magnitude 1 and points in the same direction as the original — except when the input is the zero vector, which has no defined direction.
Use cases
- Graphics and game engines: convert a movement vector into a pure direction before applying a separate speed scalar.
- Physics simulations: normalize force or velocity vectors to isolate directional components for projection and decomposition.
- Machine learning: unit-normalize feature vectors before computing cosine similarity or feeding them into neural-network layers.
Frequently asked questions
What is a unit vector?
A unit vector is a vector with magnitude exactly 1. It encodes only direction, not scale. Any non-zero vector v can be normalized to v̂ = v ÷ |v|.
Why does the zero vector have no unit vector?
Normalization requires dividing by |v|. When |v| = 0 the division is undefined, and the zero vector carries no directional information, so no unit vector exists.
Does normalizing change the direction of the vector?
No. v̂ always points in the exact same direction as v; only the length changes to 1. Negative components remain negative and the proportions between components are preserved.
Related tools
See all →Calculate the area and perimeter of a rectangle from its width and height, with a labeled diagram.
Calculate the area and circumference of a circle from its radius, with a labeled diagram.
Calculate the area (Heron’s formula) and perimeter of a triangle from its three sides.
Calculate the area and perimeter of a trapezoid from its two parallel sides, height, and legs.