← Back
Track Pageviews for Your Netlify Logs
Netlify Log Drains require a Netlify Enterprise plan and Team Owner access.
Step 1: Create a Log Drain
- Open your Netlify dashboard and select your site
- Go to Analytics & metrics → Log Drains
- Click Enable a log drain and select General HTTP endpoint
- Select only Traffic logs. Leave function, edge function, deploy, and WAF logs unchecked
- Leave Exclude personally identifiable information (PII) unchecked so Netlify includes the client IP and user agent needed to identify agents
Step 2: Configure the Destination
- For Full URL, enter:
https://api.knownagents.com/logs/netlify
- For Authorization header, enter:
Bearer YOUR_ACCESS_TOKEN
- Copy your access token from your Known Agents project Settings page and replace
YOUR_ACCESS_TOKEN - Select JSON for Log Drain Format
- Click Connect
Step 3: Test Your Integration
- Navigate to the Projects page, select your project, and open Settings
- Click Send a Test Visit, then open Realtime
Netlify batches traffic logs, so the test visit may take a few minutes to appear.