Source: https://goodhandover.co.uk/tools/vector-dot-product-calculator/

[Computer science maths](https://goodhandover.co.uk/tools/computer-science-maths/#year-1) / Year 1

🔒 Files never leave your device

# Vector dot product calculator

Find the dot product, vector lengths, cosine similarity and angle. Your inputs stay on your device.

## Set up your task

Ready. Processing stays in this browser.

Files and text stay on your device. [Privacy details](https://goodhandover.co.uk/privacy/).

 

## How to use Vector dot product calculator

Find the dot product, vector lengths, cosine similarity and angle. The pre-filled problem gives you a worked starting point. Compare the response with your own working before trying the self-check below.

 

- Check the example inputs: First vector, Second vector.

- Change the inputs for your problem. Results update as you type, so finish entering the values before copying an answer.

- Use the working to check an intermediate value or assumption. Then change the example as suggested in the self-check and compare the result.

 

## Supported inputs and limits

Use two real-valued vectors of the same dimension with up to 64 components. Separate components by spaces or commas.

 

## How it works

The dot product measures how two vectors align. Algebraically it adds the products of matching coordinates. Geometrically it equals the product of their lengths times the cosine of the angle. A negative result indicates that a nonzero pair forms an obtuse angle.

The dot product depends on scale. Cosine similarity removes scale by dividing by both lengths. That distinction matters when comparing document feature vectors or directions whose magnitudes have different meanings. A zero vector still participates in the dot product, but it cannot define a geometric direction.

 

## Example

Run the pre-filled example. Its first result is “Dot product: 32”.

First vector

1 2 3

Second vector

4 5 6

Dot product: 32
Lengths: 3.74165739  8.77496439
Cosine: 0.974631846 · Angle: 12.9331545°

 

## Questions about Vector dot product calculator

### What happens when one input is a zero vector?

The dot product is zero. The angle and cosine need two nonzero lengths, so those outputs are undefined.

### What does cosine similarity of zero mean?

For two nonzero vectors the angle is 90 degrees, so each vector is perpendicular to the other.

### Enter the two vectors 1 0 and 0 2.

The dot product is zero, the lengths are one and two, and the angle is 90 degrees.

 
 

## Related tools

[Year 1: Foundations](https://goodhandover.co.uk/tools/computer-science-maths/#year-1)

- [Matrix multiplication calculator](https://goodhandover.co.uk/tools/matrix-multiplication-calculator/)

- [Descriptive statistics calculator](https://goodhandover.co.uk/tools/descriptive-statistics-calculator/)

- [Modular exponentiation calculator](https://goodhandover.co.uk/tools/modular-exponentiation-calculator/)

- [Polynomial derivative calculator](https://goodhandover.co.uk/tools/polynomial-derivative-calculator/)

 

Last updated 24 November 2026
