Rules Overview
Rules let you tell nsin how to handle visitors to your site. With a rule you can send people to a new page, change how caching works, slow down attackers, or block bad traffic — all without touching your server.
You create rules in the Rules section of your dashboard.
How a rule works
Section titled “How a rule works”Every rule has two parts:
- When — the condition that decides if the rule should run (for example,
“when the address starts with
/old-page”). - Then — the action to take (for example, “redirect to
/new-page”).
If a visitor’s request matches the When, nsin does the Then.
The kinds of rules
Section titled “The kinds of rules”| Rule | What it does | Guide |
|---|---|---|
| Redirect | Send visitors from one address to another. | Redirects |
| Cache Rule | Change how a page is cached (or skip the cache). | Cache Rules |
| Rate Limiting | Slow down visitors who make too many requests. | Rate Limiting |
| WAF (Firewall) | Block harmful or unwanted traffic. | WAF |
Create a rule
Section titled “Create a rule”- Open the Rules section.
- Click Add Rule.
- Pick the rule type.
- Set the When condition.
- Set the Then action.
- Save.
The order of rules matters
Section titled “The order of rules matters”Rules run from top to bottom. If two rules could match the same visitor, the one higher up runs first. You can drag rules to reorder them.
Turning rules on and off
Section titled “Turning rules on and off”You don’t have to delete a rule to stop it. Use the toggle next to each rule to turn it off, then back on later if you need it.
Ready to make your first one? Start with Redirects — they’re the easiest.