Target a no-code web experiment to a specific URL
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 39.9k
- Forks
- 3.4k
- Avg merge
- 7h 27m
- Merged PRs (30d)
- 222
Description
Feature request
Describe the solution you'd like
So, I'm using the no-code web experiments, I'm trying to modify the copy on a banner we have on our blog, but I want this change to be visible only on that blog post, however, it is showing on every other blog post (if I roll out to 50% of users, when they get the variant, if they navigate to other blog posts, they'll see the changed copy, they should not, the change should only show on the blog post we defined).
Workaround
Update the element selector to target a body class that's only present on the page.
Debug info
- [ ] PostHog Cloud, Debug information: [please copy/paste from https://us.posthog.com/settings/project-details#variables]
- [ ] PostHog Hobby self-hosted with `docker compose`, version/commit: [please provide]
- [ ] PostHog self-hosted with Kubernetes (deprecated, see [`Sunsetting Kubernetes support`](https://posthog.com/blog/sunsetting-helm-support-posthog)), version/commit: [please provide]
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the no-code web experiments entry point and how an experiment currently applies changes across blog posts. Confirm the URL-targeting behavior and related tests, if present. Done means a variant appears only on the blog post URL selected for the experiment, including after navigating to other posts.
Written by the indexing model from the issue text.
Assessment
- Domain
- frontend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100