| title | Datacenter Proxies |
|---|
Datacenter proxies use IP addresses assigned from datacenter servers to route your traffic and access locations around the world. With a shorter journey and simplified architecture, datacenter proxies are both the fastest and most cost-effective proxy option.
Datacenter proxies provide a stable exit IP within a single browser session — every tab, request, and reconnection inside that session exits through the same IP, and it does not rotate mid-session (unlike residential).
Across separate sessions, Kernel does not guarantee the same exit IP from a managed datacenter proxy. If a destination site requires the exact same IP across every session — for example, an IP allowlist, or a managed auth connection whose health checks and reauths must look like the same client — use a custom (BYO) proxy pointed at infrastructure you control.
Datacenter proxies require a country to route traffic through:
```typescript Typescript/Javascript import Kernel from '@onkernel/sdk';const kernel = new Kernel();
const proxy = await kernel.proxies.create({ type: 'datacenter', name: 'my-us-datacenter', config: { country: 'US', }, });
const browser = await kernel.browsers.create({ proxy_id: proxy.id, });
```python Python
from kernel import Kernel
kernel = Kernel()
proxy = kernel.proxies.create(
type="datacenter",
name="my-us-datacenter",
config={
"country": "US",
}
)
browser = kernel.browsers.create(proxy_id=proxy.id)
country(optional) - ISO 3166 country code (e.g.,US,GB,FR) orEUfor European Union exit nodesbypass_hosts(optional) - Array of hostnames that bypass the proxy and connect directly (max 100 entries)
Configure specific hostnames to bypass the proxy:
```typescript Typescript/Javascript import Kernel from '@onkernel/sdk';const kernel = new Kernel();
const proxy = await kernel.proxies.create({ type: 'datacenter', name: 'datacenter-with-bypass', config: { country: 'US', }, bypass_hosts: [ 'localhost', 'internal.service.local', '*.amazonaws.com', ], });
```python Python
from kernel import Kernel
kernel = Kernel()
proxy = kernel.proxies.create(
type="datacenter",
name="datacenter-with-bypass",
config={
"country": "US",
},
bypass_hosts=[
"localhost",
"internal.service.local",
"*.amazonaws.com",
]
)
Bypass hosts support exact hostnames and wildcard subdomains (*.example.com). See the overview for full details.