File Downloads
Clickport automatically tracks when visitors click links to downloadable files. There is nothing to configure. As soon as the tracker is installed, download clicks are recorded alongside your other analytics data.
Which file types are tracked?
The tracker detects clicks on links that end with any of these file extensions:
The check is case-insensitive, so .PDF and .pdf are both detected.
How detection works
When a visitor clicks any link on your site, the tracker checks whether the link's URL ends with a tracked file extension. If it does, the tracker sends a click event with the file URL and the link's visible text. The event is sent using fetch with keepalive: true, so it is delivered reliably even when the click causes a page navigation.
Detection happens on the <a> element, so it works for standard HTML links, links inside buttons, and links wrapped in other elements. If a visitor right-clicks and selects "Save As" without a normal click event firing, the download is not tracked.
What data is captured
Each download click records:
- File URL - The full href of the download link (e.g.
https://yoursite.com/files/report.pdf) - Link text - The visible text of the link the visitor clicked (trimmed to 200 characters)
- Page - The page the visitor was on when they clicked the download link
- Session - The download is associated with the visitor's current session
Where downloads appear in the dashboard
Session timeline
When you expand a session in the Sessions panel, download clicks appear inline in the page timeline with a C badge (click event). The file URL and link text are shown so you can see exactly what was downloaded.
Goals panel
You can create a goal that tracks specific file downloads as conversions. Use the Click goal type with a condition matching the file URL. For example, to track PDF downloads:
- Goal type: Click
- Condition: Click URL contains
.pdf
This lets you see download conversion rates, track which traffic sources drive the most downloads, and monitor download trends over time in the Goals panel.
Outbound links panel
If the download link points to an external domain, the click also appears in the Outbound Links panel alongside other external link clicks.
Tips
- Use descriptive link text. The tracker captures the visible text of the download link. "Download the 2025 Annual Report" is more useful in your analytics than "Click here."
- Filter by file type. Use the dashboard's cross-filtering to filter by click URL containing
.pdf,.zip, or any other extension to isolate specific file types. - Set up a goal for important downloads. If a file download represents a business conversion (a whitepaper, a product brochure, a price list), create a Click goal for it so it shows up in your KPIs and conversion rate.
Other automatic tracking
File downloads are one of several things Clickport tracks automatically. You might also be interested in:
- Outbound Links - Clicks on links to external websites
- Forms - Form submissions
- Engagement - Scroll depth and time on page