About the Vector Calculator
Vectors describe quantities that have both size and direction, such as force, velocity and displacement. This vector calculator takes two vectors in two or three dimensions and gives all the usual results at once: their sum and difference, the dot product, the cross product, the length of each vector, the angle between them, the unit vector of each and the projection of the first onto the second. Enter each vector as numbers separated by commas, such as 1, 2, 3. The results are shown in clean notation and can be copied. It is meant for physics and maths students, game developers and anyone who needs to check vector work quickly.
Updated October 2026
How to use the Vector Calculator
- 1Enter vector A as two or three numbers separated by commas.
- 2Enter vector B with the same number of parts.
- 3Read the dot product and angle in the main result.
- 4Check the table for the sum, difference, cross product, lengths, unit vectors and projection.
- 5Copy the summary.
Worked example
Take A = (1, 2, 3) and B = (4, 0, −1). The sum is (5, 2, 2), the difference (−3, 2, 4) and the dot product 1. The length of A is the square root of 14, about 3.742, and of B the square root of 17, about 4.123. The angle between them is arccos(1 ÷ 15.43), about 86.3 degrees, so they are almost perpendicular. The cross product is (−2, 13, −8).
Where vectors are used
- Physics: force, velocity, acceleration, work and torque.
- Games and graphics: directions, lighting, collisions.
- Engineering: stresses and moments.
- Geometry: areas of parallelograms and volumes of boxes.
- Navigation: wind and current corrections.
Common slips
The order matters for the cross product: A × B is the opposite of B × A. The dot product is a single number, not a vector. When you measure the angle between vectors, remember that arccos returns values from 0 to 180 degrees, so it never gives a reflex angle. Make sure both vectors use the same units and the same coordinate system before combining them.
Related tools
The Midpoint Calculator works with points on a plane, the Matrix Calculator handles larger arrays of numbers, the Pythagorean Theorem Calculator finds lengths in right triangles and the Inverse Trig Calculator turns ratios into angles.
Features
- 2D and 3D vectors
- Sum, difference and scaling
- Dot product and cross product
- Lengths, unit vectors and projection
- Angle between vectors in degrees
- Clear messages for mismatched sizes
Frequently asked questions
What is the dot product?
The dot product multiplies matching parts and adds them: for (1, 2, 3) and (4, 0, −1) it is 1×4 + 2×0 + 3×(−1) = 1. It equals the product of the lengths times the cosine of the angle between the vectors, and is zero when they are perpendicular.
What is the cross product?
In three dimensions the cross product gives a vector perpendicular to both inputs, with a length equal to the area of the parallelogram they span. For (1, 2, 3) × (4, 0, −1) it is (−2, 13, −8). It is not defined in plain 2D, so the calculator shows the single z-value instead.
How do I find the angle between two vectors?
Divide the dot product by the product of the lengths and take the arccosine. For (1, 0) and (0, 1) the dot product is 0, so the angle is 90 degrees.
What is a unit vector?
A vector of length 1 pointing in the same direction. Divide each part by the vector's length. The unit vector of (3, 4) is (0.6, 0.8). The zero vector has no direction.
What does projection mean?
The projection of A onto B is the part of A that lies along B. It equals B times the dot product A·B divided by B·B. Physicists use it to find the component of a force along a direction.
Can I use more than three dimensions?
This calculator handles two or three parts. The dot product, sum, difference and length work the same way in any number of dimensions, so you can extend the formulas by hand.