> ## Documentation Index
> Fetch the complete documentation index at: https://docs.toolip.io/llms.txt
> Use this file to discover all available pages before exploring further.

# How to Set Up Toolip With NGINX

> Integrate Toolip with NGINX to efficiently route traffic, mask domains, and manage connections securely. Follow this guide to configure NGINX with Toolip proxies for enhanced performance and flexibility.

## What is NGINX?

**NGINX** is a high-performance web server and reverse proxy used for load balancing, caching, and securing connections. By integrating NGINX with **Toolip**, you can efficiently route traffic, optimize performance, and improve security by masking proxy domains.

<Tip>
  Targeting search engines like Google, Bing, or Yandex requires a specialized proxy to ensure stable access and avoid blocks. **Toolip’s Search Engine ISP Proxies** are designed specifically for this, providing reliable performance where standard proxies may fail. If your proxy test isn’t working on search engines, switching to **Search Engine ISP Proxies** can resolve the issue.
</Tip>

## How to Set Up Toolip With NGINX

<Steps>
  <Step title="Install NGINX">
    1\. Install **NGINX** following the [official installation guide](https://nginx.org/en/download.html). Ensure you're using version **1.15.10 or higher**.

    2\. Check that your server’s IP is **not** whitelisted in Toolip to avoid conflicts.
  </Step>

  <Step title="Configure the NGINX Core Settings">
    1\. Open the main NGINX configuration file:

    ```bash theme={null}
    sudo nano /etc/nginx/nginx.conf
    ```

    2\. Update the following parameters:

    * **Set `worker_processes`** to `auto` for dynamic optimization.

    * **Set `worker_connections`** to `200` (or more, based on traffic load).

    3\. Add the following line at the end of the `http` section:

    ```bash theme={null}
    include /etc/nginx/sites-enabled/*;
    ```

    4\. Save and close the file.

    Your updated `nginx.conf` should look like this:

    ```nginx theme={null}
    worker_processes auto;
    user www-data;

    error_log /var/log/nginx/error.log info;
    events {
        worker_connections 200;
    }

    http {
        include /etc/nginx/mime.types;
        access_log /var/log/nginx/access.log combined;

        server {
            server_name localhost;
            listen 127.0.0.1:80;
            error_page 500 502 503 504 /50x.html;
        }

        include /etc/nginx/sites-enabled/*;
    }
    ```
  </Step>

  <Step title="Create a Proxy Configuration File">
    1\. Create the directory for custom configurations:

    ```bash theme={null}
    sudo mkdir -p /etc/nginx/sites-enabled
    ```

    2\. Create a new configuration file:

    ```bash theme={null}
    sudo nano /etc/nginx/sites-enabled/toolip.conf
    ```

    3\. Add the following configuration:

    ```nginx theme={null}
    server {
        listen 24000-24100;
        location / {
            resolver 8.8.8.8;
            proxy_pass http://127.0.0.1:$server_port;
            proxy_set_header Host $host;
            proxy_set_header X-Real-IP $remote_addr;
        }
    }
    ```

    4\. Save and close the file.
  </Step>

  <Step title="Restart NGINX">
    1\. Apply the changes by restarting NGINX:

    ```bash theme={null}
    sudo service nginx restart
    ```
  </Step>

  <Step title="Test the Proxy Configuration">
    1\. Verify the proxy connection by running:

    ```bash theme={null}
    curl --proxy http://YOUR_SERVER_IP:24000 "http://lumtest.com/myip.json" -v
    ```

    *(Replace `YOUR_SERVER_IP` with your actual server IP.)*

    2\. Expected response:

    ```json theme={null}
    {
      "ip": "43.252.31.41",
      "country": "US",
      "asn": {
        "asnum": 207990,
        "org_name": "HostRoyale Technologies Pvt Ltd"
      },
      "geo": {
        "city": "Chicago",
        "region": "IL",
        "postal_code": "60602",
        "latitude": 41.8874,
        "longitude": -87.6318
      }
    }
    ```
  </Step>

  <Step title="Monitor NGINX Traffic">
    1\. To confirm NGINX is routing traffic properly, check your proxy manager logs.

    2\. Ensure that the "sent from" IP matches your NGINX server's IP address.
  </Step>
</Steps>

With **Toolip** successfully integrated into **NGINX**, your infrastructure is now optimized for **secure proxy routing, domain masking, and load balancing**. Whether you're handling **web scraping, SEO automation, or secure traffic management**, this setup enhances performance and reliability.
