No KYC — no ID, no selfie, no documents
Choose 1 GB

Help center · checked 13 November 2026

How do I target a country or a city with AfricaProxies?

Last updated: · 5 min read

Quick answer

How do I target a country or a city with AfricaProxies?

Open the Proxy generator of your plan and choose Country, City and Internet provider: AfricaProxies writes them into the proxy username, at no extra cost, across 49 sub-Saharan locations. Choose Rotating for a new IP per connection or Sticky to keep one IP from 1 to 30 minutes. City availability varies with the devices online.

In brief
  • Three location fields: Country, City, Internet provider (ISP); each defaults to any.
  • Username format: USERNAME-country-ng-city-lagos-session-ID-ttl-30, built by the generator.
  • Sessions: Rotating, or Sticky with common durations of 5, 10, 15 and 30 minutes.
  • Price: targeting is included in every plan, from the 1 GB plan at $1.23.
  • Limit: a city or ISP is served only when a residential device is online there.

Which parameters can the username carry?

AfricaProxies counted 5 targeting parameters in its gateway username format on 13 November 2026. The generator fills them in; they can also be typed by hand.

Targeting parameters of the AfricaProxies proxy username, with an example for each
ParameterGenerator fieldExampleEffect
countryCountrycountry-keExit in Kenya (two-letter country code)
cityCitycity-nairobiExit in that city when a device is online
asnInternet provider (ISP)asn-NUMBERExit on that provider's network
sessionIP rotation: Stickysession-a1b2c3Same IP for every request with this ID
ttlSession durationttl-30Minutes the sticky IP is kept, 1 to 30

Full pattern: USERNAME-country-{cc}-city-{city}-asn-{asn}-session-{id}-ttl-{minutes}. Leave a part out to accept any value.

How do you build a Lagos or Nairobi proxy in the generator?

Six steps on the Proxy generator tab of a residential plan.

  1. Choose the login

    Under Use the login of, keep the main login or pick a sub-user.

  2. Set the location

    Pick the Country, for example Nigeria, then the City, for example Lagos. Leave Internet provider on any provider unless the test needs one network.

  3. Set the rotation

    Under IP rotation choose Rotating or Sticky; for Sticky, pick a common duration or type a session duration from 1 to 30 minutes.

  4. Choose protocol and format

    Select HTTP(S) or SOCKS5, then one of the 5 output formats.

  5. Generate

    Set the number of lines, from 1 to 1,000; New sessions creates fresh session IDs.

  6. Test and export

    Click Test it for the first line, then copy the list or use Download .txt.

curl -x http://USERNAME-country-ng-city-lagos-session-a1b2c3-ttl-30:[email protected]:7777 https://api.ipify.org

Should you use rotating or sticky sessions?

Rotating for many independent requests, sticky when several requests must come from the same IP. A price crawl over thousands of product pages suits rotation; a checkout flow, a logged-in app test or an ad preview with several page loads suits a sticky session.

The published rule for sticky mode is: Sticky sessions keep the same IP for the time you set (ttl, in minutes), up to 30 minutes. The IP can change earlier, for example if the residential device goes offline. In rotating mode, each new connection receives an IP from the pool; to change IP on every request, send one request per connection. The guide to rotating and sticky sessions compares both modes with examples.

What happens when a city or ISP is not available?

The request fails or times out instead of silently leaving the city: AfricaProxies does not promise that every city or network has a device online at every moment. Residential IPs belong to real devices that connect and disconnect.

Three ways to handle it:

  • retry after a short pause, since devices come back;
  • drop the ISP and keep the city, or drop the city and keep the country;
  • for a study that depends on one city, run a small test at the hours you plan to work before buying a large plan.

Record an unavailable exit as unavailable, not as a result for the target. Country pages such as the Lagos page describe the local networks, and the locations directory lists the 49 countries and territories.

Does targeting cost more or use more traffic?

No: country, city and ISP targeting are included in the per-GB price of every plan. A request through Lagos costs the same traffic as a request through any Nigerian IP, and Usage counts all data sent and received through the proxy (upload and download, headers included). 1 GB = 1,000,000,000 bytes. Connection attempts that fail before reaching the target are not counted.

The only cost of narrow targeting is availability: the tighter the filter, the fewer devices match. The price page gives the price of each plan, and the connection guide covers host, ports and passwords.

Frequently asked questions

Can I get a Lagos IP with AfricaProxies?

Yes, by choosing Nigeria and Lagos in the Proxy generator. AfricaProxies serves the city when a residential device is online there, so availability varies.

How long can I keep the same IP?

AfricaProxies keeps a sticky IP for the session duration you set, from 1 to 30 minutes. The IP can change earlier if the residential device goes offline.

Can I choose MTN, Airtel or Safaricom?

The generator of AfricaProxies has an Internet provider (ISP) field, which adds the provider's network to the username. Whether a given operator is listed depends on the devices online in that country.

Does AfricaProxies offer state or ZIP targeting in Africa?

No. AfricaProxies targets by country, city and ISP in its 49 sub-Saharan locations.

How many proxies can I generate at once?

The AfricaProxies generator exports from 1 to 1,000 lines per run, each with its own session ID in sticky mode.

Verdict
  • Use the generator rather than typing usernames: Country, City, ISP, Rotating or Sticky up to 30 minutes, 1 to 1,000 lines.
  • Test the exact city before a large plan: targeting is free, but a city or network only answers when a device is online.

Try city targeting with 1 GB

Country, city and ISP in the username, from $1.23.

1 GB $1.23 · Account funding from $25

Choose 1 GB