URL rules
URL rule operators
Each URL rule compares the current page's path (or full URL) against a value you specify:
| Operator | Matches when |
| --------------------- | -------------------------------------- |
| equals | The path is exactly the value |
| starts with | The path begins with the value |
| ends with | The path ends with the value |
| contains | The path includes the value anywhere |
| matches | The path matches a glob pattern |
| does not equal | The path is not the value |
| does not start with | The path does not begin with the value |
| does not contain | The path does not include the value |
What's compared
By default, URL rules compare against the pathname — the part of the URL after the domain, before any ? query string.
For https://app.example.com/dashboard/users?tab=active:
- Pathname:
/dashboard/users - Full URL:
https://app.example.com/dashboard/users?tab=active
Switch to Full URL matching in the rule settings if you need to match query parameters.

Examples
Show on the dashboard home only:
URL path equals /dashboard
Show on all pages under /settings:
URL path starts with /settings
Show on any user profile page:
URL path matches /users/*/profile
Show everywhere except the billing page:
URL path does not start with /settings/billing
Glob patterns
The matches operator supports simple glob syntax:
| Pattern | Matches |
| ------- | ------------------------------------ |
| * | Any single path segment (no slashes) |
| ** | Any path (including slashes) |
Examples:
/users/*/profile— matches/users/123/profilebut not/users/123/settings/profile/admin/**— matches/admin/,/admin/users,/admin/settings/roles
Multiple URL rules

You can add multiple URL rules to a single flow. By default they use AND logic — all rules must match. This lets you narrow the target:
URL path starts with /dashboard
URL path does not contain /onboarding
Shows on any dashboard page except the onboarding section.
Trailing slashes
Zenstep normalizes trailing slashes during comparison — /dashboard and /dashboard/ are treated as equivalent. You don't need to add both.
Hash-based routing
If your app uses hash-based routing (e.g., /#/dashboard), use a Full URL rule instead of a path rule:
Full URL contains #/dashboard
SPA navigation
Zenstep re-evaluates targeting rules on client-side navigation (pushState / replaceState events). Flows will show and hide correctly as users navigate between pages in a single-page app without a full page reload.
Some SPA frameworks (particularly older React Router versions) delay route
changes slightly. If you notice flows showing on the wrong page briefly, add a
small delay setting to the flow (under Advanced settings) to let the route
stabilize before evaluation.
Was this helpful?
Related articles