<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Sourav Jha</title>
    <description>The latest articles on DEV Community by Sourav Jha (@jhasourav07).</description>
    <link>https://dev.to/jhasourav07</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3773793%2Fe5048d59-619f-4e90-b241-19dc8d59bda1.png</url>
      <title>DEV Community: Sourav Jha</title>
      <link>https://dev.to/jhasourav07</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/jhasourav07"/>
    <language>en</language>
    <item>
      <title>I Thought Building an Anonymous Email Platform Would Be Easy. I Was Wrong.</title>
      <dc:creator>Sourav Jha</dc:creator>
      <pubDate>Wed, 10 Jun 2026 19:55:54 +0000</pubDate>
      <link>https://dev.to/jhasourav07/i-thought-building-an-anonymous-email-platform-would-be-easy-i-was-wrong-4cjb</link>
      <guid>https://dev.to/jhasourav07/i-thought-building-an-anonymous-email-platform-would-be-easy-i-was-wrong-4cjb</guid>
      <description>&lt;p&gt;Over the past few weeks, I built &lt;strong&gt;PostMarker&lt;/strong&gt;, a platform that allows users to send anonymous emails and receive replies without exposing their real email addresses.&lt;/p&gt;

&lt;p&gt;At first, the idea sounded straightforward:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;User writes a message.&lt;/li&gt;
&lt;li&gt;Email gets delivered.&lt;/li&gt;
&lt;li&gt;Recipient replies.&lt;/li&gt;
&lt;li&gt;Sender receives the reply.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Simple, right?&lt;/p&gt;

&lt;p&gt;Not even close.&lt;/p&gt;

&lt;p&gt;What looked like a weekend project quickly turned into one of the most technically challenging systems I've built so far.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Problem
&lt;/h2&gt;

&lt;p&gt;Most anonymous messaging platforms only support one-way communication.&lt;/p&gt;

&lt;p&gt;I wanted to build something different.&lt;/p&gt;

&lt;p&gt;I wanted users to:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Send an anonymous email&lt;/li&gt;
&lt;li&gt;Receive replies&lt;/li&gt;
&lt;li&gt;Maintain a conversation&lt;/li&gt;
&lt;li&gt;Never reveal their real email address&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This introduced a completely new set of challenges.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Architecture
&lt;/h2&gt;

&lt;p&gt;PostMarker is built using:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Next.js&lt;/li&gt;
&lt;li&gt;MongoDB&lt;/li&gt;
&lt;li&gt;Nodemailer&lt;/li&gt;
&lt;li&gt;IMAP&lt;/li&gt;
&lt;li&gt;SMTP&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The flow looks like this:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;User creates a conversation.&lt;/li&gt;
&lt;li&gt;A unique thread is generated.&lt;/li&gt;
&lt;li&gt;A temporary email alias is assigned.&lt;/li&gt;
&lt;li&gt;The outbound email is delivered through SMTP.&lt;/li&gt;
&lt;li&gt;Replies are collected through IMAP.&lt;/li&gt;
&lt;li&gt;Messages are synchronized into a private inbox.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Instead of storing messages forever, conversations automatically expire after 7 days.&lt;/p&gt;

&lt;h2&gt;
  
  
  Technical Challenges
&lt;/h2&gt;

&lt;h3&gt;
  
  
  1. Anonymous Replies
&lt;/h3&gt;

&lt;p&gt;Sending emails is easy.&lt;/p&gt;

&lt;p&gt;Receiving replies anonymously is hard.&lt;/p&gt;

&lt;p&gt;I needed a system that could:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Match replies to the correct conversation&lt;/li&gt;
&lt;li&gt;Verify the reply belongs to the intended recipient&lt;/li&gt;
&lt;li&gt;Prevent abuse&lt;/li&gt;
&lt;li&gt;Maintain privacy&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;To solve this, PostMarker uses:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Custom email headers&lt;/li&gt;
&lt;li&gt;Thread identifiers&lt;/li&gt;
&lt;li&gt;Reply verification&lt;/li&gt;
&lt;li&gt;Sender validation&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  2. Private Inboxes
&lt;/h3&gt;

&lt;p&gt;I didn't want users creating accounts.&lt;/p&gt;

&lt;p&gt;Instead, PostMarker generates a secure access token.&lt;/p&gt;

&lt;p&gt;The token acts as the inbox key.&lt;/p&gt;

&lt;p&gt;For additional security:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Tokens are never stored in plaintext&lt;/li&gt;
&lt;li&gt;SHA-256 hashes are stored instead&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Even if the database is compromised, inbox access tokens cannot be recovered.&lt;/p&gt;

&lt;h3&gt;
  
  
  3. Abuse Prevention
&lt;/h3&gt;

&lt;p&gt;Anonymous platforms are magnets for abuse.&lt;/p&gt;

&lt;p&gt;Several protections were added:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Rate limiting&lt;/li&gt;
&lt;li&gt;Reply validation&lt;/li&gt;
&lt;li&gt;Alias verification&lt;/li&gt;
&lt;li&gt;Thread ownership checks&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Without these protections, the platform could easily become a spam relay.&lt;/p&gt;

&lt;h3&gt;
  
  
  4. Email HTML Security
&lt;/h3&gt;

&lt;p&gt;Emails can contain:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Tracking pixels&lt;/li&gt;
&lt;li&gt;Embedded scripts&lt;/li&gt;
&lt;li&gt;Malicious HTML&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;PostMarker sanitizes email content before rendering it inside the inbox using DOMPurify.&lt;/p&gt;

&lt;p&gt;This prevents XSS attacks and protects users from malicious email content.&lt;/p&gt;

&lt;h2&gt;
  
  
  What I Learned
&lt;/h2&gt;

&lt;p&gt;This project taught me more than I expected about:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;SMTP&lt;/li&gt;
&lt;li&gt;IMAP&lt;/li&gt;
&lt;li&gt;Email infrastructure&lt;/li&gt;
&lt;li&gt;Security engineering&lt;/li&gt;
&lt;li&gt;System design&lt;/li&gt;
&lt;li&gt;Building products around real-world constraints&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;One lesson stood out:&lt;/p&gt;

&lt;p&gt;Building software is often less about writing code and more about handling edge cases.&lt;/p&gt;

&lt;p&gt;The happy path is usually easy.&lt;/p&gt;

&lt;p&gt;The difficult part is making sure everything still works when things go wrong.&lt;/p&gt;

&lt;h2&gt;
  
  
  What's Next?
&lt;/h2&gt;

&lt;p&gt;PostMarker is still evolving.&lt;/p&gt;

&lt;p&gt;Future improvements include:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Better analytics&lt;/li&gt;
&lt;li&gt;Enhanced alias management&lt;/li&gt;
&lt;li&gt;More anti-abuse protections&lt;/li&gt;
&lt;li&gt;Improved inbox experience&lt;/li&gt;
&lt;li&gt;Custom domains&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Try It Yourself
&lt;/h2&gt;

&lt;p&gt;GitHub:&lt;br&gt;
&lt;a href="https://github.com/JhaSourav07/postmarker" rel="noopener noreferrer"&gt;https://github.com/JhaSourav07/postmarker&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Live Demo:&lt;br&gt;
&lt;a href="https://postmarker.vercel.app" rel="noopener noreferrer"&gt;https://postmarker.vercel.app&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Feedback, suggestions, and contributions are always welcome.&lt;/p&gt;

&lt;p&gt;If you've built something involving SMTP, IMAP, or email infrastructure, I'd love to hear about your experience in the comments.&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>anonymous</category>
      <category>opensource</category>
    </item>
  </channel>
</rss>
