Sous proxy / Integrations / Botasaurus

Password proxy in Botasaurus

In Botasaurus the proxy goes right into the @browser decorator. The library handles the login and password itself, but it needs Node.js for that.

HTTPHTTPSLogin and passwordRotation and sticky
Botasaurus · proxy
http://LOGIN:PASSWORD@HOST:PORT
["http://...", "http://..."]
✓ IP: Germany, residentialRun

Why use a proxy in Botasaurus

Botasaurus is a Python framework for scraping with and without a browser, focused on getting past bot protection. The proxy is set with the proxy parameter of the @browser decorator as a string or a list. For a password proxy the botasaurus-proxy-authentication package spins up a local proxy via the Node.js library proxy-chain.

What to pick

Take an HTTP proxy as http://LOGIN:PASSWORD@HOST:PORT. For a large number of pages rotation fits; for flows with a login, a sticky session. Several sticky lines can be passed as a list.

Residential

from $0.6 / GB

Home ISP addresses. The main choice for accounts and protected sites.

VIP

$2 / GB

Hand-picked clean IPs, faster and more stable than regular residential.

Mobile

$4 / GB

Carrier IPs, for platforms that check addresses strictly.

Step-by-step setup

Button names are given exactly as they appear in Botasaurus.

  1. Install Botasaurus

    Run pip install botasaurus. For a password proxy the machine must have Node.js.

  2. Export the proxy

    Take login:pass@ip:port in @SousProxyBot or the dashboard and prepend http://.

  3. Pass proxy to the decorator

    @browser(proxy="http://LOGIN:PASSWORD@HOST:PORT"). With a list, Botasaurus takes proxies in turn for different tasks.

  4. Run it

    Save the example as ip.py and run python ip.py.

  5. Check the IP

    The function returns the page text with the proxy IP. Botasaurus also saves the result to the output folder.

Code example

Put in your own HOST, PORT, LOGIN and PASSWORD from the bot or the dashboard.

python
from botasaurus.browser import browser, Driver


@browser(proxy="http://LOGIN:PASSWORD@HOST:PORT")
def check_ip(driver: Driver, data):
    driver.get("https://api.ipify.org?format=json")
    return driver.get_text("body")


check_ip()

Tested by running it

We ran this example ourselves: Python 3.13.18 · botasaurus 4.0.97 (botasaurus-driver 4.0.101) · Node.js 22.23.5 · Chrome for Testing 153.0.8010.12. Real output below, IP hidden.

Terminal · ip.py
$ python ip.py && cat output/check_ip.json
Running
Written
     output/check_ip.json
"{\"ip\":\"proxy IP\"}"

And this is the response when the password is wrong:

$ python ip.py && cat output/check_ip.json
Running
Written
     output/check_ip.json
"This site can\u2019t be reached\n\nThe webpage at https://api.ipify.org/?format=json might be temporarily down or it may have moved permanently to a new web address.\n\nERR_TUNNEL_CONNECTION_FAILED"

Common errors

The issues people most often bring to support.

!

Error about node or javascript when starting with a proxyA password proxy needs Node.js: proxy-chain runs on it. Install Node.js and run again.

!

Site sees your IPThe proxy was passed to the wrong decorator. @browser has the proxy parameter; make sure the function is wrapped in it.

!

Proxy login prompt in ChromeThe string lacks a scheme or has a typo. Write it in full: http://LOGIN:PASSWORD@HOST:PORT.

!

Proxy is slow on some tasksTest the line on /en/tools/proxy-checker/. With rotation some IPs are slower.

Need a proxy for Botasaurus?

Residential, VIP and mobile IPs. HTTP and SOCKS5, pay per GB, 1 GB free to try.

FAQ

Can I pass several proxies?

Yes, as a list in proxy. Botasaurus cycles through them for different data items.

Do requests without a browser need a proxy?

Botasaurus's @request also has a proxy parameter. Same string format.

Does SOCKS5 work?

We haven't tested that. HTTP is more reliable for the browser: Chrome doesn't support SOCKS5 with a password directly.