Cosine Similarity Calculator

Enter two vectors as comma-separated numbers and instantly get their cosine similarity score, angle, and supporting calculations.

Vector Inputs

Quick Examples

Enter two vectors on the left and click Calculate.

Copied!

Summary

Enter two vectors as comma-separated numbers and instantly get their cosine similarity score, angle, and supporting calculations.

How it works

  1. Enter the first vector as comma-separated numbers (e.g. 1, 2, 3).
  2. Enter the second vector with the same number of dimensions.
  3. Click Calculate (or press Enter) to run the computation.
  4. The tool computes the dot product of the two vectors.
  5. It divides the dot product by the product of both magnitudes.
  6. The result is displayed as a similarity score (-1 to 1) and the angle in degrees.

Use cases

  • Compare document embeddings in natural language processing.
  • Measure similarity between user preference vectors in recommendation systems.
  • Validate machine learning feature vectors during model development.
  • Compute angles between vectors in physics and engineering problems.
  • Check how closely two sets of survey ratings align.
  • Debug cosine similarity implementations in your own code.
  • Explore vector mathematics interactively for learning purposes.

Frequently Asked Questions

Last updated: 2026-06-11 · Reviewed by Nham Vu