홈 / 사용 사례 / 로테이션 프록시
무료 로테이션 프록시 풀
로테이션 프록시는 각 요청을 다른 IP에서 보냅니다. 유료 서비스가 필요 없습니다 — 매시간 검증되는 무료 목록으로 나만의 풀을 만들 수 있습니다.
로테이션 패턴
세 부분: 검증된 풀을 불러오고, 호출마다 다음 프록시로 교체하며, 타이머로 풀을 새로고침해 죽은 프록시를 교체합니다.
import itertools, time, requests
LIST = "https://raw.githubusercontent.com/xyzs996/free-proxy-health-list/main/proxies/all/data.json"
def load_pool():
data = requests.get(LIST, timeout=15).json()
def to_url(p):
proto, hp = p["protocol"], p["proxy"]
if proto.startswith("socks5"): return f"socks5h://{hp}"
if proto.startswith("socks4"): return f"socks4://{hp}"
return f"http://{hp}"
return [to_url(p) for p in data]
pool = load_pool()
cycle = itertools.cycle(pool)
refreshed = time.time()
def get(url, tries=10):
global pool, cycle, refreshed
if time.time() - refreshed > 1800:
pool = load_pool(); cycle = itertools.cycle(pool); refreshed = time.time()
for _ in range(tries):
px = next(cycle)
try:
r = requests.get(url, proxies={"http": px, "https": px}, timeout=8)
if r.ok: return r
except requests.RequestException:
continue
raise RuntimeError("no working proxy this round")
print(get("https://httpbin.org/ip").json())
풀을 건강하게 유지하는 팁
적중률을 높이려면 fast 또는 top-1000 하위 집합에서 시작하고, 연속 2회 실패한 프록시는 버리며, 성공률이 떨어지면 더 자주 새로고침하세요. 목록은 매시간 재검증됩니다.
자주 묻는 질문
무료 로테이션 프록시를 만들 수 있나요?
예 — 검증된 목록을 로테이션하고 실패 시 다음을 재시도하면 됩니다. 로테이션+재시도가 무료 프록시를 쓸 만하게 만드는 핵심입니다.
풀은 얼마나 자주 새로고침?
15~60분마다. 원본 목록은 매시간 검사됩니다.
언제 유료로?
SLA가 있는 안정적인 로테이션 URL이 필요하면 Pro API를 보세요.