# Headers and Cookies
The Smart Proxy automatically forwards most of your request headers and cookies to the target website via the Crawling API. This allows you to send custom headers or cookies as you would with a direct request. The User-Agent
header from your request is forwarded as-is to the target. If you send a blank User-Agent
, the Smart Proxy will rotate it for you.
Certain headers used by the proxy itself, such as Host
and Proxy-Authorization
, are not forwarded.
Here's an example of how to send custom headers and cookies with your request. The headers and cookies in the example below will be forwarded by the Smart Proxy and used when making the request to https://httpbin.org/anything
.
Using HTTP:
# Using Smart Proxy with custom headers and cookies
curl \
-H "Accept-Language: en-US,en;q=0.9" \
-H "X-Custom-Header: My-Custom-Value" \
-H "User-Agent: MyCustomBrowser/1.0" \
--cookie "mycookie=myvalue; anothercookie=anothervalue" \
-x "http://[email protected]:8012" \
-k "https://httpbin.org/anything"
Using HTTPS:
# Using Smart Proxy with custom headers and cookies
curl \
-H "Accept-Language: en-US,en;q=0.9" \
-H "X-Custom-Header: My-Custom-Value" \
-H "User-Agent: MyCustomBrowser/1.0" \
--cookie "mycookie=myvalue; anothercookie=anothervalue" \
-x "https://[email protected]:8013" \
-k "https://httpbin.org/anything"