How tracking works
Email Tracker uses invisible 1x1 pixel images embedded in outgoing emails to detect when recipients open messages. The tracking system consists of three main components:- Token generation - Creates unique tracking identifiers
- Pixel injection - Embeds tracking pixels in compose dialogs
- Open detection - Records opens when pixels are requested
Token generation
When you compose an email, the extension generates a unique tracking token containing metadata about the message.Token structure
Tokens are compact, URL-safe base64-encoded JSON arrays:Token encoding process
The extension encodes tokens in the background service worker:The
user_id is generated once during extension installation and persists across sessions. The email_id is a new UUID for each message.Pixel injection
The content script monitors Gmail compose dialogs and injects tracking pixels when you send messages.Compose dialog detection
The extension scans for compose dialogs and binds event listeners:Send intent detection
The extension detects send actions through multiple event types:1
Mousedown events
Captures clicks on send buttons before Gmail processes them
2
Keyboard shortcuts
Detects Ctrl+Enter or Cmd+Enter send shortcuts
3
Recipient changes
Re-injects pixel if recipient changes after initial injection
Pixel HTML structure
The injected pixel is a 1x1 transparent image with zero opacity:Open detection
When a recipient opens the email, their email client requests the tracking pixel from your server.Pixel endpoint
The server handles pixel requests atGET /t/:token.gif:
Transparent pixel
The server returns a 1x1 transparent GIF for all requests:Request metadata extraction
The server captures rich metadata from each pixel request:End-to-end flow
Here’s the complete lifecycle of a tracked email:1
User composes email
Gmail compose dialog is detected by content script
2
Token generation
Background worker generates
user_id, email_id, and tracking token3
Pixel injection
Content script injects hidden
<img> tag with pixel URL into message body4
Email sent
Message is sent through Gmail with embedded tracking pixel
5
Recipient opens email
Recipient’s email client renders HTML and requests pixel URL
6
Server records open
Tracking server decodes token, extracts metadata, checks for duplicates and suppression, stores event in database
7
Dashboard updated
Extension and dashboard APIs reflect new open count
Frequently asked questions
Why use a GIF instead of a PNG?
Why use a GIF instead of a PNG?
GIF is the smallest image format for a 1x1 transparent pixel (43 bytes base64-encoded). It’s widely supported and recognized as the standard for tracking pixels.
Can recipients block tracking pixels?
Can recipients block tracking pixels?
Yes. Email clients may:
- Block external images by default (requires user to “Load images”)
- Proxy images through their servers (e.g., Gmail Image Proxy)
- Strip tracking pixels entirely
What happens if the token is invalid?
What happens if the token is invalid?
The server catches decoding errors and still returns a transparent GIF with a 200 status. Invalid requests are logged but don’t create database records.
How does tracking work with Gmail's image proxy?
How does tracking work with Gmail's image proxy?
Gmail proxies images through Google’s servers (The system also measures latency between sender suppression signals and proxy hits for debugging.
googleimageproxy). The tracker detects these requests by User-Agent and IP prefix:What data is stored for each open?
What data is stored for each open?
Each open event stores:
email_id,user_id,recipient(from token)opened_at(timestamp)ip_address,user_agent(from request)geo_country,geo_region,geo_city,latitude,longitude(from GeoIP)device_type(currently always ‘other’)is_duplicate,is_sender_suppressed,suppression_reason(flags)
Related features
Sender suppression
Learn how identity-based suppression prevents counting sender self-opens
Deduplication
Understand how duplicate opens are detected and filtered
Dashboard analytics
Explore dashboard APIs and analytics features