38

My website sends emails to me with the same subject and they are being grouped into conversations even if I delete old ones (Mail, Gmail). I know I can change the subject to prevent this, but is there a header or something else that can be added to do this without forcing unique subject lines?

2
  • gmail grouping infuriates me. Maybe I am too old school and like to read oldest to newest. I don't get gmail grouping.
    – ojblass
    May 2, 2014 at 17:55
  • 3
    ojblass, it can be turned off in your preferences. But I need something that works from the sending side.
    – Louis W
    May 2, 2014 at 18:27

2 Answers 2

54

On the top of my head, there are two methods to avoid threading:

  • set the SMTP header X-Entity-Ref-ID with any value. This is what Google+ notifications do.
  • change the sender email (you can use From: [email protected]). This is what Facebook notifications do.

The threading will be made if you force it with Reference or Reply-To.

7
  • YES! Wow, this is saving me a ton of hair-pulling. All the other answers I found to this question were adding random numbers to subject lines - I don't want to send that to my users! And GMAIL destroys the css on my HTML emails. THANK YOU RDS!
    – pinhead
    Jan 15, 2015 at 1:12
  • 1
    Wow, thanks for this but, how do you know about X-Entity-Ref-ID ? is it a gmail only thing ? I can't find anybody else talking about this in the internet :) May 21, 2015 at 6:00
  • 2
    The X-Entity-Ref-ID did not work for me; +randomstring did! Thx.
    – Mike N
    Jan 8, 2016 at 9:54
  • 4
    For me X-Entity-Ref-ID: null did work, both for GMail as well as a client like Airmail.
    – thijsai
    Apr 25, 2017 at 8:44
  • 1
    Oh my god - thank you so much for that X-Entity-Ref-ID trick! Been pulling my hair out with this issue for two days.
    – Dawid Dahl
    Aug 29, 2022 at 6:37
0

The situation has changed since 2019.

I found a solution in https://workspaceupdates.googleblog.com/2019/03/threading-changes-in-gmail-conversation-view.html.

Setting a header of the form References: <[email protected]>, with a unique UUID for each email is enough to solve this.

Tested a few times today and I confirm it works.

1
  • Unsure if it works – I get emails threaded even in the absence of an X-Entity-Ref-ID header. Just same title and sender seem enough.
    – kashmiri
    Jan 18, 2023 at 13:23

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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