Setup guide
Add FetchNode to your Django site
Create one project for each site you run. Paste the browser snippet into your base template, paste the Django snippet into settings.py, and send a test error to confirm everything is connected.
Create a project key first
FetchNode needs a project key before it can accept errors, traffic, and pageviews from this site.
Use your project key
Replace PUBLIC_PROJECT_KEY before deploying. Once you create a project key, this page fills it in for you.
Step 1
Browser snippet
Paste this before </head> in the base template used by the site. It records browser errors and lightweight pageviews.
Step 2
Django settings.py snippet
Paste this at the bottom of settings.py. It captures server exceptions, 404s, request duration, and database query counts.
settings.py
Paste this block at the bottom of the file.
FetchNode filters scanner noise on the server, so you do not need extra 404 rules in this snippet.
Step 3
Verify it works
Browser error
Open your website console and run:
throw new Error("FetchNode test — browser")
Server error
Add a temporary URL, visit it once, then remove it:
path("test-fetchnode/", lambda r: (_ for _ in ()).throw(Exception("FetchNode test — server")))
Then open the project dashboard. Within a few seconds you should see the test issues, pageviews, users, sessions, and top pages.
Assistant prompt
If you prefer to let your coding assistant make the change, copy this prompt into the project you want to connect.
Prompt
Use this in the codebase you want to connect.
Create a project for each site
Each project gets its own key, errors, traffic, users, sessions, and top pages.