Magnitude of a Vector Formula: How to Find It in 2D and 3D
By Dr. Muhammad Amjad Khadim (PhD Mathematics) · Updated December 2026
Every vector has two properties: a direction and a size. The size is called the magnitude, and it is the first thing you calculate in almost every vector problem, whether you are normalising a direction, finding a distance, measuring a force or computing the angle between two vectors. In this guide I explain the magnitude of a vector formula in 2D and 3D, show how to find it from components or from two points, and connect it to unit vectors, the dot product and the cross product. Each section has a worked example you can check in seconds.
What is the magnitude of a vector?
The magnitude of a vector v, written |v| or ‖v‖, is its length: the distance from its tail to its head. It is a single non-negative number with no direction. A velocity vector's magnitude is speed; a force vector's magnitude is the strength of the force in newtons; a displacement vector's magnitude is the straight-line distance travelled.
The magnitude of a vector formula
Because the components of a vector form the sides of a right triangle (or a box in 3D), Pythagoras' theorem gives the length directly.
| Dimension | Vector | Magnitude |
|---|---|---|
| 2D | v = (x, y) = xi + yj | |v| = √(x² + y²) |
| 3D | v = (x, y, z) = xi + yj + zk | |v| = √(x² + y² + z²) |
| n dimensions | v = (v₁, v₂, …, vₙ) | |v| = √(v₁² + v₂² + … + vₙ²) |
In words: square each component, add the squares, take the square root. Negative components cause no trouble, because squaring removes the sign.
How to find the magnitude of a vector: step by step
- Write the vector in component form, for example v = (2, −3, 6).
- Square each component: 4, 9, 36.
- Add them: 4 + 9 + 36 = 49.
- Take the square root: |v| = √49 = 7.
Example 1: a 2D vector
v = (3, 4): |v| = √(9 + 16) = √25 = 5. This is the famous 3-4-5 triangle shown above.
Example 2: a 3D vector in i, j, k form
v = 4i − 4j + 7k: |v| = √(16 + 16 + 49) = √81 = 9.
Example 3: when the answer is not a whole number
v = (1, 2, 2) gives √9 = 3, but v = (1, 1, 1) gives √3 ≈ 1.732. Leave exact answers as surds unless you are asked for a decimal.
Magnitude of a vector between two points
To find the magnitude of the vector from A to B, first build the vector, then measure it:
This is exactly the distance formula. Example: A(1, 2, −1) and B(4, 6, 11). AB = (3, 4, 12), so |AB| = √(9 + 16 + 144) = √169 = 13.
Magnitude and unit vectors
A unit vector has magnitude 1, so the magnitude of a unit vector is always exactly 1. To turn any non-zero vector into a unit vector pointing the same way, divide by its magnitude:
For v = (2, −3, 6), |v| = 7, so û = (2/7, −3/7, 6/7). Check: (4 + 9 + 36)/49 = 1 ✓. For a full walkthrough, see our guide on the unit vector formula.
Two properties are worth memorising:
- Scaling: |kv| = |k| |v|. Doubling a vector doubles its length; multiplying by −1 reverses it but keeps the length.
- Triangle inequality: |a + b| ≤ |a| + |b|. A detour is never shorter than the direct route.
Magnitude and the dot product
The dot product of a vector with itself gives the square of its magnitude: v · v = |v|². That is why magnitudes appear in the angle formula
You cannot find the angle between two vectors or a vector projection without first computing magnitudes.
Magnitude of the cross product
The magnitude of the cross product has a geometric meaning: it is the area of the parallelogram spanned by the two vectors.
Example: a = (1, 2, 0) and b = (3, 1, 0). Then a × b = (0, 0, 1·1 − 2·3) = (0, 0, −5), so |a × b| = 5. Check with the formula: |a| = √5, |b| = √10 and a · b = 5, so cos θ = 5/√50 ≈ 0.707, giving θ = 45° and sin θ ≈ 0.707. Then √5 · √10 · 0.707 = √50 · 0.707 = 5 ✓. The triangle with these two sides has half that area, 2.5. More on this in our cross product guide.
Magnitude of a resultant force
In physics, forces add as vectors, and the magnitude of the resultant force tells you how strong the combined push is.
Method 1: components
F₁ = (3, 0) N and F₂ = (0, 4) N give R = (3, 4) N, so |R| = 5 N.
Method 2: the cosine rule form
For two forces of size F₁ and F₂ with angle θ between them, R² = F₁² + F₂² + 2F₁F₂ cos θ. With F₁ = 10 N, F₂ = 6 N and θ = 60°: R² = 100 + 36 + 2(10)(6)(0.5) = 196, so R = 14 N. See also work done and torque using vectors.
From magnitude and direction back to components
If you know a 2D vector's magnitude r and its angle θ from the positive x-axis, its components are x = r cos θ and y = r sin θ. A velocity of 20 m/s at 30° is (20 cos 30°, 20 sin 30°) ≈ (17.32, 10) m/s. Squaring and adding gets you back to 20, because cos²θ + sin²θ = 1.
Common mistakes
- Forgetting the square root. x² + y² + z² is the magnitude squared, not the magnitude.
- Squaring a negative incorrectly on a calculator. Type (−3)², not −3², or you will get −9.
- Adding magnitudes instead of vectors. |a + b| is usually not |a| + |b|.
- Mixing units. Convert every component to the same unit before squaring.
Frequently asked questions
What is the magnitude of a vector formula?
For v = (x, y) the magnitude is |v| = √(x² + y²). For v = (x, y, z) it is |v| = √(x² + y² + z²). In general, square every component, add them, and take the square root.
How do you find the magnitude of a vector between two points?
Subtract the coordinates to get the vector AB = (x₂ − x₁, y₂ − y₁, z₂ − z₁), then apply the magnitude formula. The result is the distance between the two points.
Can the magnitude of a vector be negative?
No. A magnitude is a length, so it is always zero or positive. Only the zero vector has magnitude 0.
What is the magnitude of a unit vector?
Exactly 1. You turn any non-zero vector into a unit vector by dividing it by its own magnitude: û = v / |v|.
What is the magnitude of the cross product?
|a × b| = |a| |b| sin θ, where θ is the angle between the vectors. It equals the area of the parallelogram formed by a and b.
How is magnitude related to the dot product?
The dot product of a vector with itself is the square of its magnitude: v · v = |v|². So |v| = √(v · v).
How do you find the magnitude of a resultant force?
Add the force vectors component by component, then take the magnitude of the result. For two forces at an angle θ you can also use R² = F₁² + F₂² + 2F₁F₂ cos θ.
Summary
The magnitude of a vector is its length. Use |v| = √(x² + y²) in 2D and |v| = √(x² + y² + z²) in 3D, subtract coordinates first when the vector joins two points, divide by the magnitude to get a unit vector, and remember that v · v = |v|² and |a × b| = |a||b| sin θ. With those few facts you can handle distances, forces, angles and areas. Paul's Online Notes covers the basics in its vectors section, and you can test your answers with our free vector calculators.
Comments
Post a Comment