Counting number of downloads of a release

Hi all,

    For our project, dmtcp, we would like to count the number of downloads for our releases.  There seems to be no easy way to do this.  The best results from Google that I can find are:

  Github help (but this seems to show only how to get the download count for a specific file (e.g., .tar.gz)  that we must first create separately and upload to Github and then point to it on the Releases page)


  [Github release stats]( “Project for “Github release stats””) (but when I try this on our dmtcp project, it tells me: “There are no releases for this project”;  I suppose that’s true, since we didn’t upload specific files to Github)

If I understand the Github Releases tab correctly, it checks for any tags in the Github master branch.  Any tags are considered as releases, and the entry on the Releases page includes an automatically packaged .zip or .tar.gz of the commit that the tag points to.  But since the .zip/.tar.gz files are apparently generated dynamically, it appears that there is no single, corresponding fixed file, for which Github will record the download count.

Do I understand correctly the issue of counting the number of downloads of a Github release?  We are looking into hack-ish solutions, but it seems surprising to me that there is no simple solution out there.  Thanks for any help.

1 Like

You are correct in your understanding that while creating a tag in your repository creates something that shows up in the releases tab, it isn’t a release that downloads will be tracked for. In order for GitHub to track downloads, you have to generate a release and upload an “asset” that is associated with that release. Then GitHub will track downloads of each artifact and you can query the GitHub API to get download counts for each asset for a given release.

Isn’t this an odd practice, why do I need to upload an “asset” while github automatically generates zipball and tarball already? Does github track the downloads of thoseautomatically generates zipball and tarball? Thank you.


Here is a web app that shows github release statistics in a clean format:

1 Like

Great share @dr-nyt. Thank you!