# Email in should strip Fwd's and Re's when creating a new topic

**URL:** https://meta.discourse.org/t/email-in-should-strip-fwds-and-res-when-creating-a-new-topic/21215
**Category:** Feature
**Created:** [16 באוקטובר,‏ 2014,‏ 9:01pm UTC](https://meta.discourse.org/t/email-in-should-strip-fwds-and-res-when-creating-a-new-topic/21215 "2014-10-16T21:01:19Z")
**Posts on this page:** 9
**Page:** 1

<div class="post-metadata">

### Author: ![downey](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/downey/32/166878_2.png) [@downey](https://meta.discourse.org/u/downey)
#### Post date: [16 באוקטובר,‏ 2014,‏ 9:01pm UTC](https://meta.discourse.org/t/email-in-should-strip-fwds-and-res-when-creating-a-new-topic/21215/1 "2014-10-16T21:01:19Z")

</div>

**As a user, I want to be able to forward an email message to Discourse to start a discussion, without having the topic include all the “FW:”, “Fwd:”, “RE:”, etc. cluttering up the topic line, so that it’s easier to read what the topic is without the useless email junk.**

Saw this today when someone forwarded a message to start a discussion about a document he received. There was about 15 characters of junk that I ended up stripping out of the topic title.

---

<div class="post-metadata">

### Author: ![tobiaseigen](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/tobiaseigen/32/539204_2.png) [@tobiaseigen](https://meta.discourse.org/u/tobiaseigen)
#### Post date: [18 באוקטובר,‏ 2014,‏ 5:33pm UTC](https://meta.discourse.org/t/email-in-should-strip-fwds-and-res-when-creating-a-new-topic/21215/2 "2014-10-18T17:33:22Z")

</div>

Why not just edit the subject line before posting? Or go back later to clean up the post?

---

<div class="post-metadata">

### Author: ![lake54](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/lake54/32/121955_2.png) [@lake54](https://meta.discourse.org/u/lake54)
#### Post date: [18 באוקטובר,‏ 2014,‏ 5:36pm UTC](https://meta.discourse.org/t/email-in-should-strip-fwds-and-res-when-creating-a-new-topic/21215/3 "2014-10-18T17:36:07Z")

</div>

> [@tobiaseigen](#):
>
> Why not just edit the subject line before posting? Or go back later to clean up the post?

It’s something that could be done by Discourse automatically and reduce an admin’s workload (and keep things nice and tidy from the off)

---

<div class="post-metadata">

### Author: ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)
#### Post date: [18 באוקטובר,‏ 2014,‏ 6:27pm UTC](https://meta.discourse.org/t/email-in-should-strip-fwds-and-res-when-creating-a-new-topic/21215/4 "2014-10-18T18:27:51Z")

</div>

Can you propose a regex here? This might be tricky with nested fwd: re: etc and how many variants? Also needs localization does it not?

---

<div class="post-metadata">

### Author: ![downey](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/downey/32/166878_2.png) [@downey](https://meta.discourse.org/u/downey)
#### Post date: [19 באוקטובר,‏ 2014,‏ 1:52pm UTC](https://meta.discourse.org/t/email-in-should-strip-fwds-and-res-when-creating-a-new-topic/21215/5 "2014-10-19T13:52:46Z")

</div>

Here’s a good start:

> <https://stackoverflow.com/questions/9153629/regex-code-for-removing-fwd-re-etc-from-email-subject>

---

<div class="post-metadata">

### Author: ![jeff\_y](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jeff_y/32/200242_2.png) [@jeff\_y](https://meta.discourse.org/u/jeff_y)
#### Post date: [11 בדצמבר,‏ 2020,‏ 9:39pm UTC](https://meta.discourse.org/t/email-in-should-strip-fwds-and-res-when-creating-a-new-topic/21215/6 "2020-12-11T21:39:38Z")

</div>

I think most people forwarding a message to the forum will follow email conventions, which include prepending "Fwd: " and "Re: " to forwards and replies. However, forum content uses a different convention of not including the prefixes. Therefore, I think the email receiver should do the conversion.

Some Discourse importers already support removing these prefixes:

> <https://github.com/discourse/discourse/blob/ae114a6ee8f2e4f9abd1bbd536d34e6bc55fea23/script/import_scripts/mbox/settings.yml#L46>

---

<div class="post-metadata">

### Author: ![JonathanShaw](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jonathanshaw/32/532672_2.png) [@JonathanShaw](https://meta.discourse.org/u/JonathanShaw)
#### Post date: [12 בדצמבר,‏ 2020,‏ 8:41am UTC](https://meta.discourse.org/t/email-in-should-strip-fwds-and-res-when-creating-a-new-topic/21215/7 "2020-12-12T08:41:14Z")

</div>

I would definitely expect users to fail to do this, and I would have expected discourse to do it automatically.

---

<div class="post-metadata">

### Author: ![Lhc\_fl](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/lhc_fl/32/268115_2.png) [@Lhc\_fl](https://meta.discourse.org/u/Lhc_fl)
#### Post date: [29 בספטמבר,‏ 2023,‏ 2:29pm UTC](https://meta.discourse.org/t/email-in-should-strip-fwds-and-res-when-creating-a-new-topic/21215/10 "2023-09-29T14:29:16Z")

</div>

I’ve been having some trouble with this lately. Maybe add some settings like this to the sitesettings to allow the administrator to set which prefixes should be stripped?

 ![image](https://global.discourse-cdn.com/meta/original/4X/c/d/7/cd7050dbdfed18378cdbbf3ea9111f43ab57c420.png)

---

<div class="post-metadata">

### Author: ![Lhc\_fl](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/lhc_fl/32/268115_2.png) [@Lhc\_fl](https://meta.discourse.org/u/Lhc_fl)
#### Post date: [31 באוקטובר,‏ 2023,‏ 8:29am UTC](https://meta.discourse.org/t/email-in-should-strip-fwds-and-res-when-creating-a-new-topic/21215/11 "2023-10-31T08:29:11Z")

</div>

Okay, finally I solved my problem by writing my own plugin. I think this partially solves the problem in this topic

> [@Email Extension](https://meta.discourse.org/t/email-extension-allow-reply-topic-with-re-via-email-and-etc/283982):
>
> information_sourceSummary Add some extra functionality to Discourse’s email systemhammer_and_wrenchRepository Link [https://github.com/Lhcfl/email-extension](https://github.com/Lhcfl/email-extension)open_bookInstall Guide [How to install plugins in Discourse](https://meta.discourse.org/t/install-plugins-in-discourse/19157)Features Allows you to reply to posts via the email address containing the post\_id. For example: reply+p%{post\_id}@discourse.example.com Will automatically determine the Re: prefix and send your email to the correct topic to reply to …
