Question about crates.io downloads counter

Hi everyone,

I already published 16 versions of my library. And I noticed that the more versions, the more downloads per day. For example, for today it is about 300 downloads. And I cannot believe all that downloads are from real people.

Could somebody explain how the downloads counter on crates.io actually works? Does it increment every time someone rebuilds their application with my library as a dependency? Or are all those downloads from bots? Or are they all real people?

It's apparently mainly CI, so yes bots. But the pattern in your crate is just increased popularity on Feb 27-28 combined with the weekday/weekend cycle. Not sure why today is so high, but it might be noise (one person can do 300 downloads if they've misconfigured something).

The number should be exactly the number of times the package is downloaded from crates.io, which happens the first time a specific package and version is used on an installation of rust. Building two crates on the same machine that depend on the same version of your crate should only increment it once. CI is different since it's not often configured to cache dependencies, so it's often just the count of the number of commits to some repository.

1 Like

Thank you for the detailed explanation !

See also

2 Likes