Update Play Count in iTunes for Windows

Last updated on December 8th, 2017 at 01:52 am

I lost the playcount in iTunes for Windows for some of my tracks.

Tonight I wanted to fix that without editing the Library.xml file – that’s too extreme. I envy Mac owners as they have wonderful Applescript collections to manage iTunes.

I found the awesome Liquid Parallax scripts but didn’t like manually editing the javascript file to set the new play count. So I hacked it together with some Windows Script Hosting magic to invoke a input dialog box in javascript. So the script now asks you to input the new play count.

Installation instructions for Adjust Play Count in iTunes for Windows:

  1. Download AdjustPlayCount.zip and unzip the contents somewhere on your hard-drive. This will give you a 3KB file called AdjustPlayCount.wsf
    • Google Chrome doesn’t like wsf files and may block it with the message AdjustPlayCount.zip may be dangerous so Chrome has blocked it, you can use Firefox to download it or
    • go to your address bar and enter chrome://downloads/# 
    • then click KEEP DANGEROUS FILE
  2. Remember where you saved the script.

How to Adjust Play Count in iTunes for Windows:

  1. Select/highlight one or more songs in iTunes for Windows (use Shift+click or Ctrl+click to select more than one file). This can include the song now playing.
  2. Alt+Tab to your Windows Explorer window and double-click AdjustPlayCount.wsf
  3. Enter the desired new play count number in the dialog box.
  4. Click OK
  5. The script will reply with the new play count and number of files adjusted.

The script will update your iTunes for Windows play count for all the selected songs – even for the current playing song if you’ve highlighted it.

It worked for me on Windows XP and Vista Home using iTunes 10.0.1.22. In the comments you’ll see it works with Windows 7, 8 and 10 with iTunes 12+.

I provide no warranties for this script. Test it on one backed up song first. If it kills your tunes, drinks your liquor or runs off with your daughters, it’s not my fault. You’ll see in the comments it has worked with thousands of files for others.

You can open the wsf file in a text editor to read the script if you want to see what it does.

Limitations:

  1. iTunes for Windows only. It kinda needs Windows to work.
  2. AdjustPlayCount does not check or force you to type an integer in the dialog box. I don’t know what will happen, but it can’t be good.
  3. I’ve tested it with 20 songs selected. I don’t know how it would perform if you selected 1,000 songs at once. Let me know, okay? *You’ll see in the comments it’s worked with thousands of files for others.

BUGS

iTunes Match vs. Play Counts: Every few years it seems that iTunes Match screws with Play Counts for some users 2011, 2014, 2016 and 2017. It looks like iTunes 12.7.114 is doing it for one user below. Actually it is iTunes Match that stops play count sync. It seems to be random and not all users are affected. If you use iTunes Match it may affect you. Suggested temporary fixes are to deregister the PC, reboot, fix the play counts and then register the PC. That doesn’t mean the problem won’t return.

Suggestions, bug reports, questions and/or thanks in the comments. Maybe I could make it increase the play count by set number? Tell me what you think.

Update 14 April 2013: I’m thinking of a checkbox that will also reset the last played date to todays date. Again, let me know what you think.

Update 24 March 2017: If you can’t download the file using Google Chrome browser because of its security settings, you can use Firefox to get the file or do the following

  • go to your address bar and enter chrome://downloads/# 
  • then click KEEP DANGEROUS FILE

 

50 Replies to “Update Play Count in iTunes for Windows”

  1. I’m gonna try this later.

    I forgot to back up my iTunes library (not music files, they’re all safe in external HDD) when I reformatted my PC so I thought I lost my playlists built for over a decade. Looks like I can rebuild again thanks to Rocket Player, listFix, m3u8 playlists to back up from my phone, and now this script.

    Godspeed.

  2. hey, I used the script and it worked but when my itunes connected to icloud laterthe play count reset to the original value. Now it keeps on resetting so my play count for those songs is broken. Anyway to undo this?

    1. Hi @kenith What version of Windows and iTunes are you using?

      That way I can check it.

      It seems like you said you’re backing up/restoring iTunes to iCloud?

      I thought that was an iPhone setting in Settings>iCloud i.e. you back up your phone to iTunes or iCloud not both.

      1. Hi,

        Thx for the speedy response.
        I’m using itunes version 12.7.1.14 on a Windows 7 pc. I have an itunes match subscription so itunes connects to the cloud if i’m not misstaken to upload/match new songs.

        1. Yes it’s a bug on Apple’s side with iTunes Match. Doug’s AppleScripts for iTunes mentioned it last year and it was a problem Apple’s forums in 2011 and 2014 (oops!).

          There seems to be a fairly recent bug affecting track play counts–or plays–when the played count property of an iTunes track is changed with AppleScript. If iCloud Music Library or iTunes Match is enabled, the value will revert to what it was before being changed by AppleScript. It seems as though either the new play count for a track doesn’t get synced to the cloud or that the original value in the cloud has over-written the new plays value. Or something like that.

          Several scripts here (Multi-Item Edit, New Play Count, New Last Played Date, et al) that allow you to edit the play counts of your tracks are affected by this bug, which only occurs if you’re also using iCloud Music Library or iTunes Match. I am not sure if versions of iTunes prior to 12.3.3.17 are affected or if, perhaps, the bug also occurs with a track’s skipped count (I wouldn’t be surprised).

          I filed a bug report with Apple and it turns out it’s already an open issue, so Apple knows about it. Now we wait.

          https://dougscripts.com/itunes/2016/04/play-counts-bug/

Leave a Reply

Your email address will not be published. Required fields are marked *