Restore “Bounce Message” functionality to OS X Lion

For some reason, Apple decided to remove the ability to bounce email messages from the OS X Lion version of UI. They did, however, leave the API exposed, and it can be called via AppleScript.

Instructions on how to create an Automator service that can execute the AppleScript (copied here just in case):

1. Open Automator.
2. Create a new service.
3. Configure the service so that it has “no input” in “Mail”
4. Drag “Get Selected Mail Messages” into the workflow
5. Drag “Run Applescript” into the workflow
6. Use the following AppleScript, then save the workflow with a name like “Bounce Message”.

on run {input, parameters}
   tell application "Mail"
      repeat with eachMessage in input
         bounce eachMessage
      end repeat
   end tell
end run

7. In Mail, select the message you would like to bounce. Then from the “Mail” menu, choose “Services”, then click on your new service. The message will bounce.

About Kevin

Kevin Jarnot is a technologist who lives just South of Boston, MA. He is currently employed as Chief Technology Officer at Micronotes, an AI-driven conversation-marketing company based in Boston, MA.
This entry was posted in Mac. Bookmark the permalink.

71 Responses to Restore “Bounce Message” functionality to OS X Lion

  1. John G says:

    This is a terrific find. I got it to work as a Service, but not as a Workflow attached to a Rule. Any ideas on how this might be written as a Rule?

  2. Daniel says:

    Thanks, it works perfectly.

  3. CB says:

    This is a lifesaver! I REALLY wish Apple had not dropped the Bounce feature!!!

  4. A R says:

    THANK YOU!! 🙂

  5. Egor says:

    I created the service but it’s not working.

    Do i also input the column of numbers:

    Or just:
    on run {input, parameters}
    tell application “Mail”
    repeat with eachMessage in input
    bounce eachMessage
    end repeat
    end tell
    end run


  6. kent says:

    doesn’t work for me

  7. Egor says:

    I did not put numbers but it doesn’t work for me.. just not doing nothing…

  8. Alan says:

    I have the same problem as Egor. I put the code in Automator, saved it. I even tested it out in Automator and it did not come up with any errors – but when use it in Mail…nothing happens. I send myself a test e-mail from a different address, went to services and bounced it…but nothing happened, and no bounce message showed up – either in the receiving or sending e-mail account.

  9. Johan says:

    Great guide, and thanks for putting it out there! My favorite feature in Mail was “Bounce”, and alas, with OS X Lion, I lost it. However, I have the same problem as the above commenter(s). The script shows no errors in Automator, yet nothing happens (no e-mail is bounced) when I call the service in Mail, which shows up as it should.

    Tried with and without Automators standard closing “read input” that you’ve removed in your script, with no difference in results.

  10. Tyler G says:

    You won’t see anything happen in Mail, even when it does complete successfully! To test the script to see if it works, send yourself an email then bounce it.. the result will be you getting your own bounce notice! That way you can be sure it works.

    If the lack of feedback about whether or not the script has completed successfully, I’m sure you could add a third step in Automator which would give you that confirmation that it successfully completed the first two. Another option is to place an “ask for confirmation” Automator task (under utilities) in-between the two tasks.. That’s what I did, saying: ‘Are you sure you want to bounce the message(s)?’. Another fun idea (if you have Growl installed) is to use a growl notification at the end!

  11. ross says:

    I added a delete eachmessage to the script to get rid of the messages too.

  12. EN says:

    It did not show up as service in the mail program, what did I wrong?

  13. Hello,

    Good comment of Ross. By adding `delete eachMessage` after `bounce eachMessage` we will got the same result as in the previous version of Mail.


  14. Adrian says:

    I know nothing about automator, but followed the instructions above and it works. I also added `delete eachMessage` after `bounce eachMessage` and that works too.

    Well done, and thanks very much.

    My ‘runapplescript’ box now says:

    on run {input, parameters}
    tell application “Mail”
    repeat with eachMessage in input
    bounce eachMessage
    delete eachMessage
    end repeat
    end tell
    end run

  15. Eric says:

    This is fantastic – thank you. I also added the shortcut back in via Services Preferences. Once you’ve created the service in mail to bounce once again (WHAT a relief; SUCH a loss!), click on mail-service-system prefs and you can go in and click where the shortcut should be, type your shift-open apple-B shortcut in, close and reopen Mail and VOILA! Love it. Thanks again for a sharp work-around. I too thought it didn’t work but after adding the “delete eachMessage” line, and then bouncing a message to myself just to check, everything works perfectly. Awesome!

  16. Michael says:

    This can also be implemented as a rule in preferences:rules.

    The applescript that was inserted into Automator above can be pasted straight in as an action to be taken on incoming messages, so if there is a particular source of annoyance, it can be bounced upon arrival with no human intervention. You could choose to bounce the message, then delete it, or move it, flag it, etc.

    This works in pre-Lion mail, which I’m still using, but I an pretty sure it will work in the Lion’s mail as well, since the Automator service works in preLion mail.

    btw: The Automator service is a great idea. Thanks for it!

  17. Drew says:

    Hi, When i click Mail/services I get a greyed out box saying “no services apply”.

    What would cause this from happening? I’m running 10.7.2 on an iMac i5.


  18. George says:

    Suggest adding the following to the script for good measure:
    set junk mail status of eachMessage to true

    My full script now reads:

    on run {input, parameters}
    tell application “Mail”
    repeat with eachMessage in input
    bounce eachMessage
    set junk mail status of eachMessage to true
    set mailbox of eachMessage to mailbox “Trash”
    end repeat
    end tell
    end run

  19. sfpaulski says:

    thanks for the information
    works perfectly although the mail will still be in your mail box.
    to check this send yourself an email then bounce it back

    thanks again
    peace out

  20. Vonster says:

    I followed the step by step, but it doesn’t work in Apple Mail? All I get is a pop up window saying “The action “Run AppleScript” encountered an error.”

    Can you look at this screen grab of my workflow in Automator and tell me what I have set up wrong? Thanks.

    View screen grab here:

    Thanks for the help.

  21. gary says:

    Thank you so much! This works as a “bounce” but does not delete, for whatever reason…
    Any suggestions??

  22. Donna says:

    Great & thanks, works well.

  23. Barry says:

    I believe you may need “return input” right before “end run”. Also be careful that the quotes on either side of the word Mail are not the pretty ones but the standard type (“Mail”)

  24. Gil says:

    Works like a charm?
    Was wondering, could you mod the script to also flag the email as junk, and then delete it? Im not familiar with the spam filters in Mail, but I would like that option. I get far to many spam emails nowadays!

  25. Katherine Kane says:

    Since everyone else seems to understand exactly what you mean, I apologize for being such a techno-dunce. However, I have no clue as to how to find creating a an Automator script that works in mail. After significant searching, I found Automator. But I don’t know how to go from there.

    Again, for all of you techno-smart people, I apologize. But I do want to bring back Bounce, and if this works I want to do it : )

    Thank you so much!

  26. pele says:

    Thank you all for this great tip!

    Much appreciated as it works perfectly, but “shame” on Apple for removing a very useful function in the first place.

  27. BounceMyX says:

    There is an app now that allows you to bounce emails from your iPhone.

  28. Thank you Kevin for the “bounce email” help. Awesome… My gratitude is exceeded only by my excitement in seeing it work!!!! 🙂

  29. Sean says:

    Worked for me , thanks!
    Also, added a Keyboard shortcut.

  30. Carole says:

    Love it so very much. Thanks. Really missed being able to do this as needed. Set up the keyboard shortcut and that didn’t work though. Tried two characters (Command +b) as well as three (Command +Shift +b). Neither worked. Any suggestions?

  31. Roxanne says:

    Thanks so much for the information! I have never used automator before so this has opened a whole new world for me. I added ‘delete each message’ after ‘bounce each message’ as Adrian suggested and love it even more.
    George 12/29/11 suggested adding this:
    set junk mail status of eachMessage to true
    set mailbox of eachMessage to mailbox “Trash”
    Can anyone explain to me what that will do?

  32. JW says:

    This fix worked! Thanks. Directions were fantastic.

  33. Sid says:

    What you have described above works like a charm. Thanks a ton! 🙂

    Using AppleScript I saved the above code as a script. It doesn’t work when I run the script as a rule. 🙁

    I don’t understand much of coding so please help! 🙂

  34. Jason says:

    This is SO AWESOME!!!

    I had a looooooong thread going on this topic in the Apple support forums and no one knew how to do this. They said it couldn’t be done. YOU DA MAN!

    I feel like I owe you like $50.

  35. Bob S says:

    Can’t find “Run Applescript” to drag it in.

  36. Pingback: » Blog Archive » Bounce Mail

  37. Chriss says:

    worked perfectly!!! thanks a million!

  38. Bruno says:


    I realize that most of the people here are well in tune from a technical standpoint. That said, I’m not one of them. Although these directions seem to be easy enough as I’m just an outside observer, I’m unable to complete them. Will you help me out?

    About the only thing I know how to do is find and run Automator.

  39. Kevin says:

    Hi Bruno. Specifically where do you need help?

  40. Bruno says:

    I’m not trying to be funny but I literally need help with Steps 2-6 and lines 1-7 of that code and/or script. I know how to open Automator as stated but can’t get the rest of the directions beyond that point. If you have a minute, we could do this on Skype: bmchi87 or through e-mail: Thanks in advance, Kevin.

  41. Bruno says:

    Actually I just tried it and thought it worked since I saw the option come up as described in step 7 but it didn’t work.

    Here’s a screen cap of the error message:

  42. Bruno says:

    Got it to work! You can get rid of all my inquiries here, lol.

  43. Nunuv Yurbiz says:

    Does this still work? It seems to have stopped working for me. I don’t use it often, so maybe an OS update broke this? My script includes ‘delete eachMessage’ and so I see it get deleted. But I sent myself a message and then bounced it, and I didn’t then receive the bounce notification.

  44. Piterancki says:

    While the general concept works excellent and I thank you for it (like many others I found myself scratching my head on this one). I found that the bounce msg is somewhat generic and in my case follows with the following lines included:

    Reporting-MTA: dns;
    Received-From-MTA: DNS;

    I am not using a email, but road runner is my ISP… is there a way to customize the bounce msg to include/input a different above post office handler? gmail? .mac? etc?

    Thanks again for the Bounce Msg

  45. Piterancki says:

    No worries, this is way awesome anyway. I think the bounce msg while some will argue that it does nothing good for spoofed return emails (which I agree with) … does a whole lotta good for the msgs that have a return email monitored to verify the validity of the email lists.

    I’m gonna test it while taking my laptop to another location where the ISP is different. Maybe it simply takes the current ISP’s settings and plugs them into the bounce msg.

    Thanks again

  46. dnta says:

    Thank you so much for this!!

  47. hollie says:

    Works great …
    I should have just copied and pasted your script in there – took me a couple of times to get “eachmessage” to appear as one word due to auto correction. Maybe that’s why others are having a hard time.


  48. Pingback: Mac Blog

  49. Jim P. says:

    Excellent. Thanks.

  50. Pingback: Where is Bounce in Mail (Mountain Lion?)

  51. w_ says:

    May I kiss your feet?

  52. CK says:

    This does not work for me. It worked in Lion 10.7 but not in Mountain Lion 10.8.

  53. bounce master says:

    I was having trouble getting the script to run, never having used Automator before. I ran the script using the green “play” button & Automator highlighted where there was an error (it was the type of quotation marks used). Once hghlighted I was able to correct & the script now runs.

    Thanks & brilliant,

  54. Vince says:

    Kevin, U R da MAN!

    I’ve been lamenting the loss of Bounce Mail since Apple pulled it out of the Mail app. And now I have the functionality back!

    Thank you very much for such a good post.

  55. Oak says:

    Here’s a solution already made. Don’t know if it works in ML, but it does in Lion. This solution actually gives you a real button in the Mail tool bar.

  56. 1004ron says:

    I had this working great as a selectable service and automated to respond to certain senders email address while still using Mountain Lion, but since “upgrading” to Mavericks I cannot find a way to make this work at all.

    Please help.

    • Leon Horsnell says:

      I would also like to get it to work with maverick, it reduced my spam down quite a bit with mountain lion. But also marking mail as junk also helps

  57. Leon Horsnell says:

    will it work with Yosemite

  58. Larry says:

    I just found this thread and just tried the script in El Capitan and it worked today (8-13-17). Awesome. Thanks.

  59. Ron Young says:

    Still not working with Sierra

Leave a Reply to Barry Cancel reply