Sessions and IP rotation: per connection or sticky
How rotation works on the gateway, how sticky sessions hold an IP, and how to pick a session length.
Rotation without a session
With no sid in the username, every new TCP connection to the gateway leaves from a different IP in the place you asked for. Requests that reuse one open connection (HTTP keep-alive) keep the IP of that connection, so a client that opens a fresh connection per request gets a fresh IP per request.
Sticky sessions
Add sid. with 6 to 16 lowercase letters or digits and the gateway pins an exit IP to that id. Every connection that uses the same username, including the same id, leaves from the same IP until the session ends. ttl. sets the length in minutes from 1 to 120; the default is 10.
USERNAME_cc.de_sid.cart0042_ttl.30When a session ends early
Residential and mobile exits are real devices. If the device behind a session goes offline, the gateway moves the session to a new IP in the same country, state or city and keeps the id. Datacenter and ISP sessions run on servers and rarely move.
Picking a length
| Job | Pattern |
|---|---|
| Wide crawls, price lists, search pages | No session: new IP per connection |
| A short browse that needs cookies (search then product page) | sid with ttl.5 to ttl.10 |
| Checkout-free flows on your own accounts, dashboards | ttl.30 to ttl.120 |
| Many parallel sticky workers | one random sid per worker |
For many workers, make one id per worker (the dashboard can generate a list with a random id on each line). A session is not reserved for you: reusing an id after it ends starts a new session with a new IP.