Geo-targeting lets you route your traffic through proxy IPs in specific countries, states, or cities. This is critical for accessing localized content, verifying geo-restricted ads, scraping region-specific search results, and testing how your own website appears in different markets.
How Geo-Targeting Works
When you connect to a residential proxy pool, the provider assigns you an IP from their network. With geo-targeting, you specify where that IP should be located. ZentisLabs supports three levels of precision:
- Country-level: Route through any IP in a specific country (195+ countries)
- State/Region-level: Target a specific state or region (US, BR, DE, etc.)
- City-level: Pin to a specific city (1,000+ cities worldwide)
Configuration Syntax
ZentisLabs uses password-based geo-targeting. Append targeting parameters to your proxy password:
import requests
# Country targeting (Germany)proxy = "http://USER:PASS_country-de@gate.zentislabs.com:7777"
# State targeting (California, US)proxy = "http://USER:PASS_country-us_state-california@gate.zentislabs.com:7777"
# City targeting (London, UK)proxy = "http://USER:PASS_country-gb_city-london@gate.zentislabs.com:7777"
proxies = {"http": proxy, "https": proxy}r = requests.get("https://httpbin.org/ip", proxies=proxies)print(r.json())Use Cases
1. Localized SEO Monitoring
Google shows different search results based on the searcher's location. A bakery in Chicago needs to know how they rank for "best bakery near me" from a Chicago IP, not from your office in a different state.
2. Ad Verification
Advertisers use geo-targeted proxies to verify that their ads appear correctly in different markets. Check that your Facebook ads in Japan show the right creative, landing page, and pricing.
3. Price Comparison
Many e-commerce sites show different prices based on location. Airlines, hotels, and SaaS products frequently use geo-based pricing. Proxies let you see the real price from any location.
4. Content Access
Access geo-restricted content for market research, compliance testing, or content verification. Check that your streaming platform's content library is correct in each licensed region.
Multi-Location Scraping Example
import requestsimport json
locations = [ {"country": "us", "city": "new_york", "label": "New York"}, {"country": "gb", "city": "london", "label": "London"}, {"country": "de", "city": "berlin", "label": "Berlin"}, {"country": "jp", "city": "tokyo", "label": "Tokyo"}, {"country": "br", "city": "sao_paulo", "label": "São Paulo"},]
results = []for loc in locations: proxy_pass = f"PASS_country-{loc['country']}" if loc.get("city"): proxy_pass += f"_city-{loc['city']}" proxy = f"http://USER:{proxy_pass}@gate.zentislabs.com:7777" proxies = {"http": proxy, "https": proxy} r = requests.get("https://ipinfo.io/json", proxies=proxies, timeout=10) info = r.json() results.append({ "target": loc["label"], "actual_ip": info.get("ip"), "actual_city": info.get("city"), "actual_country": info.get("country"), }) print(f"{loc['label']}: {info.get('city')}, {info.get('country')}")
print(json.dumps(results, indent=2))Sticky Sessions with Geo-Targeting
Combine geo-targeting with sticky sessions to maintain the same IP across multiple requests:
# Same London IP for 10 minutesproxy = "http://USER:PASS_country-gb_city-london_session-order123@gate.zentislabs.com:7777"
session = requests.Session()session.proxies = {"http": proxy, "https": proxy}
# All requests use the same London IPfor page in range(1, 6): r = session.get(f"https://example.co.uk/products?page={page}") print(f"Page {page}: {r.status_code}")Tips for Best Results
- Use the broadest targeting that works: Country-level has more IPs available than city-level. Only narrow down if you need it.
- Match your User-Agent locale: If you're using a German IP, set your Accept-Language header to
de-DE. - Verify with IP lookup: Use our IP Lookup tool to confirm your proxy IP is in the expected location.
- Smaller cities = fewer IPs: If a city doesn't have enough IPs, widen to state or country level.
🌍 ZentisLabs supports geo-targeting in 195+ countries and 1,000+ cities with non-expiring bandwidth. Target any location from a single API endpoint.
