Documentation menu

Free proxy API

GET /api/free-proxy returns Litport's current public free-proxy observations. It requires no authentication.

Request#

curl --get 'https://litport.net/api/free-proxy' \
  --data-urlencode 'country=de' \
  --data-urlencode 'protocol=http' \
  --data-urlencode 'uptimeRating=90' \
  --data-urlencode 'sortBy=responseTimeMs_asc' \
  --data-urlencode 'limit=50'
Parameter Type Default Current behavior
country string all Case-insensitive ISO-2 code. The value is uppercased; no aliases are applied.
limit integer 50 Accepted range 10–1000. Invalid or out-of-range values are ignored.
page integer 1 Accepted range 1–1000. Invalid or out-of-range values are ignored.
sortBy string pingAt_desc Field: pingAt, responseTimeMs, or createdAt. Direction: asc or desc. Invalid values are ignored.
anonymity string all Exact filter: transparent, anonymous, elite, or unknown. Unknown values usually return an empty array.
anonymityLevel string all Deprecated alias: high = anonymous or elite, low = transparent. Exact filter. Unknown values usually return an empty array.
protocol string all Exact filter such as http, https, or socks5. Unknown values usually return an empty array.
list string all Named generated-list preset: https (HTTPS-capable), fast (rounded latency below 1000 ms), stable (rounded seven-day uptime at least 90% with at least 50 checks), or anonymous (anonymous or elite). Unknown values are ignored.
uptimeRating integer none Minimum 24-hour uptime percentage, 1–100. Invalid values are ignored.
responseTimeMs integer none Maximum HTTP response time in milliseconds, 1–10000. Invalid values are ignored.
checkedWithinMin integer none Maximum age of pingAt in minutes, 1–1440. Snapshot defaults to 30; timestamps later than request time are excluded by this freshness filter.
format string json json, csv, txt, or txt-proto. Unknown values fall back to JSON.
download flag off When present for a supported format, returns an attachment.

country uses a case-insensitive ISO-2 code and is uppercased for lookup. It has no alias table: use country=gb; country=uk may return an empty array. PPG proxy usernames have different compatibility behavior.

Response behavior#

The default JSON response is a bare array with no data envelope, total, or hasMore value. Pagination is blind: page offset is (page - 1) * limit, and an empty array means no rows matched that page.

The underlying dataset may be up to 120 seconds old, and responses send Cache-Control: public, max-age=60 on top of that, so a response may be up to about 3 minutes behind the last check; polling faster than the cache window returns the same rows. Invalid numeric parameters and invalid sortBy values are silently ignored in this version, leaving their defaults. Unknown exact filter values commonly produce an empty array rather than a 400 response.

checkedWithinMin keeps only proxies checked within the requested 1–1440 minute window. It excludes timestamps later than the request time. The paged endpoint has no default freshness filter for compatibility.

[
  {
    "protocol": "http",
    "host": "192.0.2.10",
    "port": 8080,
    "externalIp": "192.0.2.10",
    "geoCountry": "US",
    "https": true,
    "anonymity": "elite",
    "anonymityRating": 100,
    "responseTimeMs": 420,
    "uptimeRating": 97,
    "pingAt": "2026-08-25T12:00:00.000Z"
  }
]

Example addresses in this documentation are reserved for documentation and are not live proxies.

JSON fields#

Field Type Meaning
protocol string Proxy protocol.
host string Proxy hostname or IP address.
port integer Proxy port.
externalIp string Observed exit IP.
geoCountry string ISO-2 exit country.
geoCountryFlagEmoji string Country flag for display.
geoRegion string Observed exit region.
geoCity string Observed exit city.
geoTimezone string Observed exit timezone.
asn integer or string Observed autonomous system number; legacy observations may use an AS-prefixed string.
asnOrgName string Observed network organization.
https boolean true when an HTTPS request tunnels through the proxy with a valid certificate; null when not yet measured.
anonymity string Measured anonymity classification: transparent, anonymous, elite, or unknown.
anonymityRating integer Normalized anonymity score.
anonymityLevel string Deprecated alias: high = anonymous or elite, low = transparent.
anonymityLevelRating integer Deprecated alias, equal to anonymityRating.
responseTimeMs number Measured HTTP response time in milliseconds.
responseTimeRating integer Normalized response-time score.
uptimeRating integer Rounded 24-hour uptime percentage.
uptime7d number Seven-day uptime percentage, rounded to one decimal place.
checks7d integer Number of checks contributing to the seven-day uptime value.
uptime24h number 24-hour uptime percentage, rounded to one decimal place.
checks24h integer Number of checks contributing to the 24-hour uptime value.
sourcesCount integer Number of observed source lists for this proxy.
responseTimeMedianMs number Rolling median latency over recent alive checks, possibly fractional, or null when unavailable.
lastAliveAt date-time When this proxy most recently passed an alive check.
createdAt date-time When Litport first observed this proxy.
pingAt date-time When Litport last checked this proxy.

createdAt records when Litport first observed the proxy. pingAt records the last check and is the relevant freshness signal. https reports whether an HTTPS request through the proxy completed with a valid, trusted certificate; it is null until measured. anonymity reports how much the proxy exposes about itself and the caller (transparent, anonymous, elite, or unknown); anonymityLevel is a deprecated two-value alias kept for compatibility.

Consistent snapshot#

GET /api/free-proxy/snapshot returns one complete, consistently filtered generation. It defaults to checkedWithinMin=30, accepts the same filters as the list endpoint except page, limit, sortBy, format, and download, and returns up to 20,000 rows ordered by freshness. Invalid checkedWithinMin input returns 400.

{
  "generatedAt": "2026-09-09T22:40:12.000Z",
  "count": 2121,
  "totalCount": 2121,
  "truncated": false,
  "maxAgeMin": 30,
  "proxies": []
}

Both endpoints provide ETag and Last-Modified for conditional requests. Send the returned ETag in If-None-Match; a matching, valid request receives 304 Not Modified only after its current filtered response has been calculated.

CSV and text formats#

# CSV
curl 'https://litport.net/api/free-proxy?format=csv&limit=25'
# host:port, one proxy per line
curl 'https://litport.net/api/free-proxy?format=txt&limit=25'
# protocol://host:port, one proxy per line
curl 'https://litport.net/api/free-proxy?format=txt-proto&limit=25'

Use download=1 with a supported format to request an attachment. CSV is returned as text/csv; text variants use text/plain; JSON uses application/json.

JavaScript example#

const url = new URL('https://litport.net/api/free-proxy')
url.searchParams.set('country', 'us')
url.searchParams.set('limit', '25')

const response = await fetch(url)
if (!response.ok) throw new Error(`HTTP ${response.status}`)
const proxies = await response.json()

Python example#

import json
import urllib.parse
import urllib.request

query = urllib.parse.urlencode({"country": "us", "limit": 25})
with urllib.request.urlopen(f"https://litport.net/api/free-proxy?{query}") as response:
    proxies = json.load(response)

Developer resources#

Browse the free proxy list to inspect the current data, filter it in the browser, and copy a request URL for your own testing.

Use the free proxy list source to understand the published dataset, or review the free proxy SDK source when integrating the API into an application.

SDKs#

Choose a client for your runtime. Each client retrieves and filters proxy records; your application chooses how to use them.

Runtime Install Package and reference
JavaScript / TypeScript npm install @litportnet/free-proxy-sdk npm package
JavaScript / TypeScript via JSR npx jsr add @litportnet/free-proxy-sdk JSR package and API reference
C# / .NET dotnet add package Litportnet.FreeProxy .NET package
PHP composer require litportnet/free-proxy-sdk PHP package
Ruby gem install litportnet-free-proxy-sdk Ruby package
Python pip install litportnet-free-proxy-sdk PyPI package
Go go get github.com/litportnet/free-proxy-sdk/packages/go Go package and reference
Rust cargo add litportnet-free-proxy-sdk Rust crate · API reference
Perl cpanm WebService::Litportnet::FreeProxy CPAN distribution and reference
Elixir {:litportnet_free_proxy, "~> 0.1"} in mix.exs Hex package · HexDocs reference
Dart dart pub add litportnet_free_proxy pub.dev package
R install.packages("litportFreeProxy", repos = c("https://litportnet.r-universe.dev", "https://cloud.r-project.org")) R-universe package

API tools#

The Postman collection contains ready-to-run requests for filters, snapshots, CSV and text exports. No API key is needed.

Use the Docker CLI image to export records without installing a local language runtime:

docker run --rm litportnet/free-proxy-sdk:0.1.0 --protocol socks5 --limit 20 --format json

The container retrieves proxy records; it does not operate a proxy server.

Connect an AI agent with the MCP server, published as @litportnet/free-proxy-mcp and listed in the official MCP Registry as io.github.litportnet/free-proxy-mcp. Add it to any MCP-compatible client:

{
  "mcpServers": {
    "free-proxy": {
      "command": "npx",
      "args": ["-y", "@litportnet/free-proxy-mcp"]
    }
  }
}

It exposes three read-only tools: list proxies by filter, pick the highest-ranked, and summarize the current snapshot. Like every client above, it returns proxy records and does not route traffic.

Historical datasets#

For analysis of protocol, country and latency distributions, download the dated observations from Hugging Face Datasets or Kaggle. These are fixed snapshots with source provenance and a CC0 license. Check their observation date; use the API above for current records.

The Kaggle analysis notebook reads the snapshot and charts its country, protocol and latency distributions. You can run it without calling the live API.