60

On my iMac running Mountain Lion, Messages is chronically showing that I have 2 unread messages in its Dock icon. However there are no unread messages at all. I've even gone through and clicked on every single conversation in my history, just to make sure there wasn't some long-forgotten message floating around that hadn't been read.

It's not causing any major problems, but it is annoying to constantly think I've got a new message when i don't. Anyone know why this happens?

  • After observing this for some time, I noticed that it's not always 2 mesages... sometimes it's 1, sometimes it's none. I have a feeling it's related to the messages being "unread" on other devices - like my phone or ipad - for a while. Eventually the notification seems to disappear. Unless anyone can shed any other light on this, I'm going to assume that's the case and close this question. – Jonathan van Clute Mar 30 '14 at 1:05
73

I have been getting this on OS X 10.10 (Yosemite). I found a solution in the Apple discussion forums.

User LHindiii there recommended quitting Messages.app then using Activity Monitor to quit the Dock (which will automatically relaunch) and this worked for me.

  • 26
    This worked for me. An easier way (IMO) is just to use killall Dock, after you've quit the Messages app. Open it again, and you should be all set. – Craig Otis Dec 3 '14 at 22:24
  • 2
    Yosemite is really buggy compared to previous releases, in my experience. – chrishiestand Jan 2 '15 at 23:48
  • 3
    then it happens again for the next new Message. We can't do this every time, any other more permanent solution? – Mihnea Simian Jan 9 '15 at 16:08
  • @MihneaSimian Not until apple fixes the bug. That said, it’s a pretty easy workaround. – njboot Jan 26 '15 at 2:57
  • 2
    this didn't work for me at all :( – steve Jun 15 '15 at 22:35
20

I was able to solve this by right-clicking Messages in the Dock, clicking on the unread messages that showed up in the resulting contextual menu (they happened to be SMSes added via Continuity), and responding to them.

  • 1
    Well of course, but that doesn't actually address the fundamental issue. That's just what happens when you reply to any message. But these are messages that have already been replied to from another device, so there is nothing to reply to. They simply should not show as unread. – Jonathan van Clute Jan 10 '15 at 16:56
  • 1
    As in your original question, Messages was showing unread conversations in the dock icon, but by sifting through all my conversations I was unable to find one that appeared unread. I did find, however, that unread messages were indicated in the contextual menu referenced in my post. If unread messages are going to appear in the dock icon and contextual menu, they also ought to appear in Messages itself. – Joshua Pokotilow Jan 10 '15 at 20:55
  • 2
    Thank you! This fixed my problem permanently, whereas killing Messages and Dock only fixed it temporarily. As a side note, I only had to click on the unread messages. I didn't have to respond to them. – dontangg Aug 22 '15 at 2:24
  • did not work for me – Stembrain Jul 13 '16 at 12:27
18

This worked for me:

I made a script in Script Editor that ran the following:

tell application "Messages" to quit
    delay 1
tell application "Dock" to quit
    delay 1
tell application "Messages" to launch

Save the script as an application, and launch it every time Message messes up.

  • 2
    A nice pragmatic recovery script. Thanks! – bmike Mar 1 '15 at 20:38
  • Yeah! This did the job for me. Thanks. – Eric Oct 21 '15 at 14:31
  • 1
    killall Dock from the Terminal also works. – Paul Schreiber Apr 9 '16 at 17:08
  • did not work, unfortunately. – Stembrain Jul 13 '16 at 12:27
6

Easiest solution is to create a script similar to the one above with just one line like this:

tell application "Messages" to "clear unread messages"
  • 1
    That's pretty handy, thanks! I just still wish I could get to the bottom of why it does this in the first place and make it stop. – Jonathan van Clute Jul 28 '15 at 15:34
  • Certainly seems to be the simplest and most elegant workaround proposed. I will try it out next time I run across this problem (already had done the quit > killall dock > launch messages thing). – squareman Feb 24 '16 at 18:57
  • 1
    Hmm. Just happened to me again today, this simple script unfortunately did not remove the phantom icon count. The three-action script did complete the cleanup however. – squareman Feb 29 '16 at 20:11
  • did not work for me – Stembrain Jul 13 '16 at 12:27
5

I found that a combination of the previous answers works best as a script in Script Editor:

tell application "Messages" to "clear unread messages"
delay 1
tell application "Messages" to quit
delay 1
tell application "Dock" to quit
delay 1
tell application "Messages" to launch
  • 1
    did not work for me – Stembrain Jul 13 '16 at 12:28
0

try restarting your computer, right click, and open the unread messages

  • Totally inapplicable here. – Jonathan van Clute Apr 5 '16 at 14:09
  • killAll Dock worked for me once, but the next time this problem happened none of the apple script solutions, killall solutions, and right-clicking the dock icon to select unread messages worked. only this reboot cleared the stale badge. – Stembrain Jul 13 '16 at 12:34
0

None of these solutions worked for me, on High Sierra.

This did. It does involve clearing all conversations. At this point you've probably already tried that via the iMessage interface without success (as it didn't fix the unread issue).

With iMessage closed;

  • Navigate to ~/Library/Messages/ and delete it's contents.
  • Navigate to ~/Library/Containers/ find com.Apple.iChat and delete.
  • Reboot

Opening (don't) iMessage before the reboot will give you a message telling you "Messages is updating..." This will never complete.

Post reboot, all the necessary files will have been regenerated, and you'll have a brand new, clean iMessage again.

-1

Use Tinker Tool go to Dock menu and just relaunch dock

  • 1
    Welcome to Ask Different! We're trying to find the best answers and those answers will provide info as to why they're the best. Explain why you think the software you recommended is better than others out there. Providing links can also help the OP, and others, find the software and evaluate it themselves. See How to Answer on how to provide a quality answer. – fsb Sep 16 '16 at 20:01

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.