Angle Between Two Vectors Calculator

Find the angle between two vectors in 2D or 3D space. Enter the components of each vector and this calculator uses the dot product formula to return the angle in both degrees and radians, along with the dot product and magnitudes.

Calculate.co.nz is proud to be partnered with Health Based Building, a leader in sustainable and health-conscious building innovation. With over a century of experience, they develop high-performance systems like Foreverbreathe Specification, Magnum Board, and Foreverbreathe Paints to support energy-efficient, non-toxic living environments. Their commitment to healthier homes aligns with our belief that informed choices lead to better outcomes for Kiwi households.
Calculate.co.nz partner: Health Based Building
Standard formula  Dot product method: theta = arccos((A · B) / (|A| × |B|)).

1. Dimensions

2. Vector A

ax
ay
az

3. Vector B

bx
by
bz
One or more vectors has zero magnitude. The angle is undefined when a vector has no length.

Angle Between the Vectors

Angle (Degrees)
-
degrees
Angle (Radians)
-
rad
Dot Product
-
A · B
Relationship
-
vector orientation

Working

Dot product (A · B)-
Magnitude |A|-
Magnitude |B|-
|A| × |B|-
cos(theta) = dot / (|A||B|)-
theta = arccos(cos theta)-

Vector Properties

Vector A components-
Vector B components-
|A| (magnitude of A)-
|B| (magnitude of B)-
Unit vector same direction?-
Angle-
Result: Enter vector components above to calculate the angle.

How to Find the Angle Between Two Vectors

The angle between two vectors is found using the dot product formula. For vectors A and B, the formula is:

theta = arccos( (A · B) / (|A| × |B|) )

where A · B is the dot product and |A| and |B| are the magnitudes of the vectors. The result is always between 0 and 180 degrees (0 and pi radians).

Step-by-Step Method (3D Example)

For vectors A = (1, 2, 3) and B = (4, 5, 6):

StepCalculationResult
Dot product(1×4) + (2×5) + (3×6)4 + 10 + 18 = 32
Magnitude |A|sqrt(1² + 2² + 3²) = sqrt(14)3.7417
Magnitude |B|sqrt(4² + 5² + 6²) = sqrt(77)8.7750
Product |A|×|B|3.7417 × 8.775032.8327
cos(theta)32 / 32.83270.97463
Angle thetaarccos(0.97463)12.93 degrees (0.2257 rad)

This matches the calculator default output above.

Dot Product Formula

For 2D vectors A = (ax, ay) and B = (bx, by):

A · B = axbx + ayby

For 3D vectors A = (ax, ay, az) and B = (bx, by, bz):

A · B = axbx + ayby + azbz

Special Cases

AngleDot ProductRelationship
0 degreesPositive maximum (= |A||B|)Parallel (same direction)
90 degrees0Perpendicular (orthogonal)
180 degreesNegative maximum (= -|A||B|)Anti-parallel (opposite directions)

2D Example

For vectors A = (3, 4) and B = (1, 0):

A · B = 3×1 + 4×0 = 3. |A| = sqrt(9+16) = 5. |B| = 1. cos(theta) = 3/5 = 0.6. theta = arccos(0.6) = 53.13 degrees.

Applications

The angle between vectors is used in physics (force components, work = F·d×cos(theta)), computer graphics (lighting calculations, surface normals), machine learning (cosine similarity between document vectors), and engineering (structural analysis, navigation).

Related Calculators

Sources and method: Dot product and angle formula from standard linear algebra. Anton, H. and Rorres, C. (2014). Elementary Linear Algebra. 11th ed. Wiley. Stewart, J. (2015). Calculus. 8th ed. Cengage. Formula: theta = arccos((A · B) / (|A||B|)) where the result is in the range [0, pi] radians.

This calculator computes the angle between two vectors using exact floating-point arithmetic. Results are rounded to four decimal places for display. The formula is valid for any non-zero vectors in 2D or 3D space. If either vector has zero magnitude, the angle is mathematically undefined.

If you've found a bug, or would like to contact us, or learn more about James Graham and Calculate.co.nz.

Calculate.co.nz is partnered with Interest.co.nz for New Zealand's highest quality calculators and financial analysis.

Calculate.co.nz is the sister site of CalculatorHub.com, the world's largest calculator website by tool count.

All calculators and tools are provided for educational and indicative purposes only and do not constitute financial advice.

Calculate.co.nz is proudly part of the Realtor.co.nz group, New Zealand's leading property transaction literacy platform, helping Kiwis understand the home buying and selling process from start to finish. Whether you're a first home buyer navigating your first property purchase, an investor evaluating your next acquisition, or a homeowner planning to sell, Realtor.co.nz provides clear, independent, and trustworthy guidance on every step of the New Zealand property transaction journey.

Calculate.co.nz is also partnered with Health Based Building and Premium Homes to promote informed choices that lead to better long-term outcomes for Kiwi households.

Calculate.co.nz is hosted in Auckland via SiteHost new Zealand.

All content on this website, including calculators, tools, source code, and design, is protected under the Copyright Act 1994 (New Zealand). No part of this site may be reproduced, copied, distributed, stored, or used in any form without prior written permission from the owner.

About & trust: Why Calculate is NZ's most comprehensive · By the Numbers · How we compare · Editorial standards · How we keep data current · NZ finance glossary · Research & data · Financial literacy NZ · About · Privacy policy · Terms of use

Reviewed and maintained. Last reviewed 2026-07-02 and checked on a twice-monthly cycle against IRD, RBNZ and Stats NZ. How we keep data current.

© 2026 Calculate.co.nz. All rights reserved. Building free NZ calculators since 2011.