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

# Port Configuration

> How to Use Port Configuration

***

The **Port Configuration** section in the Geonode dashboard allows you to set up and manage proxy ports with specific targeting options.

This guide will help you understand how to configure ports effectively.

## **Step 1: Navigate to Port Configuration**

1. Log in to your Geonode dashboard.
2. Click on the **"Port Configuration"** tab at the top navigation bar.

<img src="https://mintcdn.com/geonode/Z2mY70PWUVAJ3gLv/images/proxy-setup/advance-config/port-configuration/navigate-to-port-configuration.png?fit=max&auto=format&n=Z2mY70PWUVAJ3gLv&q=85&s=8f85257ab9703c911f6a83ccc4cf7edd" alt="Navigate to Port Configuration" width="1907" height="936" data-path="images/proxy-setup/advance-config/port-configuration/navigate-to-port-configuration.png" />

You will see a screen similar to the provided screenshot with options on the right side and a display area for added locations.

## **Step 2: Configure Your Port Settings**

### **1. Country Targeting (Required)**

* Click on the **"Countries"** dropdown.
* Select the country you want to target.
* This is a mandatory field for geo-targeting.

<img src="https://mintcdn.com/geonode/Z2mY70PWUVAJ3gLv/images/proxy-setup/advance-config/port-configuration/country-targeting.png?fit=max&auto=format&n=Z2mY70PWUVAJ3gLv&q=85&s=d3984cd1e4a10d7908fc49473c0be2d3" alt="Country Targeting" width="1551" height="716" data-path="images/proxy-setup/advance-config/port-configuration/country-targeting.png" />

### **2. State Targeting (Optional)**

* After selecting a country, the **"States"** dropdown becomes active.
* Select a specific state if needed.

<img src="https://mintcdn.com/geonode/Z2mY70PWUVAJ3gLv/images/proxy-setup/advance-config/port-configuration/state-targeting.png?fit=max&auto=format&n=Z2mY70PWUVAJ3gLv&q=85&s=7ef52f1192cb173ff2b462376807c006" alt="State Targeting" width="1568" height="704" data-path="images/proxy-setup/advance-config/port-configuration/state-targeting.png" />

### **3. City Targeting (Optional)**

* After choosing a state, the **"Cities"** dropdown will be enabled.
* Select a city for more precise targeting.

### **4. Protocol Selection**

* Click on the **"HTTP/HTTPS"** dropdown.
* Choose between available protocols:
  * **HTTP/HTTPS** for standard web traffic.
  * **SOCKS5** if supported, for more secure or versatile connections.

<img src="https://mintcdn.com/geonode/Z2mY70PWUVAJ3gLv/images/proxy-setup/advance-config/port-configuration/protocol-selection.png?fit=max&auto=format&n=Z2mY70PWUVAJ3gLv&q=85&s=ddb43bd91eb21b9e540ba43c0064a730" alt="Protocol Selection" width="1539" height="733" data-path="images/proxy-setup/advance-config/port-configuration/protocol-selection.png" />

For a deeper understanding of protocol type, refer to [Understanding Protocol Type for Proxy Configuration](https://docs.google.com/document/d/1rjZHN-Fj6UYewLB5HbWaF22AX3VyvraabF5PEWqdSMs/edit?usp=sharing).

### **5. Session Type**

* Select the session type from the dropdown:
  * **Rotating**: Changes IPs periodically, useful for scraping and automation.
  * **Sticky**: Maintains the same IP for a session, ideal for login-related tasks.

<img src="https://mintcdn.com/geonode/Z2mY70PWUVAJ3gLv/images/proxy-setup/advance-config/port-configuration/session-type.png?fit=max&auto=format&n=Z2mY70PWUVAJ3gLv&q=85&s=606423ef4341ccf165ba37a190af4997" alt="Session Type" width="1539" height="726" data-path="images/proxy-setup/advance-config/port-configuration/session-type.png" />

For a deeper understanding of session type, refer to [Understanding Session Type for Proxy Configuration](https://docs.google.com/document/d/1udGgGDQrqsNW78Rdulv_OtW2Ox2lu6xhdSxjlIPgjOY/edit?usp=sharing).

### **6. Port Selection (Required)**

* Click on **"Select Port"** to choose a port from the range based on your configure Protocol and session type.
* This is a required field to complete the configuration.

<img src="https://mintcdn.com/geonode/Z2mY70PWUVAJ3gLv/images/proxy-setup/advance-config/port-configuration/port-selection.png?fit=max&auto=format&n=Z2mY70PWUVAJ3gLv&q=85&s=bf475a15dca8cc1d569aa1654a386f9f" alt="Port Selection (Required)" width="1539" height="752" data-path="images/proxy-setup/advance-config/port-configuration/port-selection.png" />

For a deeper understanding of port usage, refer to [Understanding Port Usage for Proxy Configuration](https://docs.geonode.com/docs/understanding-port-usage-for-proxy-configuration).

## **Step 3: Add the Configuration**

* After filling in the required fields, the **"Add"** button will become active.
* Click **"Add"** to save the port configuration.

<img src="https://mintcdn.com/geonode/Z2mY70PWUVAJ3gLv/images/proxy-setup/advance-config/port-configuration/add-the-configuration.png?fit=max&auto=format&n=Z2mY70PWUVAJ3gLv&q=85&s=62bd0361cd723aba7e424fa88d164b88" alt="Add the Configuration" width="1583" height="781" data-path="images/proxy-setup/advance-config/port-configuration/add-the-configuration.png" />

## **Step 4: Review Added Locations**

* Once added, the configured ports and locations will be displayed in the central section.
* You can view, edit, or delete configurations as needed.

<img src="https://mintcdn.com/geonode/Z2mY70PWUVAJ3gLv/images/proxy-setup/advance-config/port-configuration/review-added-locations.png?fit=max&auto=format&n=Z2mY70PWUVAJ3gLv&q=85&s=db95b9bb335d9b680627595dbeafc35f" alt="Review Added Locations" width="1919" height="934" data-path="images/proxy-setup/advance-config/port-configuration/review-added-locations.png" />

## **Port in Use**

* Once added, the configured ports and locations will have that port and can't be used by any other country.

<img src="https://mintcdn.com/geonode/Z2mY70PWUVAJ3gLv/images/proxy-setup/advance-config/port-configuration/port-already-in-used.png?fit=max&auto=format&n=Z2mY70PWUVAJ3gLv&q=85&s=0b870a2fc05e17e9f3a698e074873141" alt="Port in Use" width="1583" height="775" data-path="images/proxy-setup/advance-config/port-configuration/port-already-in-used.png" />

## **Final Result**

You're now ready to manage your ports efficiently using Geonode's Port Configuration feature!

* For Rotating:

  <img src="https://mintcdn.com/geonode/Z2mY70PWUVAJ3gLv/images/proxy-setup/advance-config/port-configuration/final-output-rotating.png?fit=max&auto=format&n=Z2mY70PWUVAJ3gLv&q=85&s=1e244fc2862f563836e85b10215adcc1" alt="For Rotating" width="1589" height="781" data-path="images/proxy-setup/advance-config/port-configuration/final-output-rotating.png" />

* For Sticky:

  <img src="https://mintcdn.com/geonode/Z2mY70PWUVAJ3gLv/images/proxy-setup/advance-config/port-configuration/final-output-sticky.png?fit=max&auto=format&n=Z2mY70PWUVAJ3gLv&q=85&s=a9c5d6e049357a6a8488a9186a17490a" alt="For Sticky" width="1582" height="772" data-path="images/proxy-setup/advance-config/port-configuration/final-output-sticky.png" />

## **Troubleshooting Tips**

* **Add button is disabled:** Ensure all required fields (Country and Port) are selected.
* **Cannot select State/City:** These options only become active after selecting a country.
* **Connection issues:** Double-check your protocol and session type settings.

If you encounter any issues, refer to the [**troubleshooting section**](/knowledge-base/troubleshooting/proxy-not-working) or [**Geonode support**](/additional-resources/support).

## **FAQs**

<AccordionGroup>
  <Accordion title="Why is the 'Add' button disabled?">
    The "Add" button remains disabled if mandatory fields are not selected. Ensure you have chosen a country and a port before proceeding.
  </Accordion>

  <Accordion title="Can I use the same port for multiple countries?">
    No, once a port is assigned to a specific country, it cannot be used for another country. You need to select a different port for each configuration.
  </Accordion>

  <Accordion title="What happens if I select 'Rotating' session type?">
    With the "Rotating" session type, your IP address will change periodically, making it ideal for tasks like web scraping or automation.
  </Accordion>

  <Accordion title="Can I switch between HTTP and SOCKS5 protocols?">
    Yes, you can select the protocol from the dropdown during configuration. However, SOCKS5 support depends on your plan and use case.
  </Accordion>

  <Accordion title="Why can't I select a state or city?">
    State and city targeting only become available after selecting a country. If they remain disabled, check if a country has been selected first.
  </Accordion>
</AccordionGroup>
