how to open port 8080 on ubuntu 25.10 , 25.04

Port 8080 is widely used for web servers, development servers, and proxy services. On Ubuntu 25.10 and 25.04, you may need to open this port to allow external connections to your applications.

Step 1: Check UFW Status

Before opening port 8080, it’s important to check whether Ubuntu’s UFW firewall is active to ensure that your firewall rules will be applied correctly.

sudo ufw status

Step 2: Open Port 8080 Using UFW

Once you’ve confirmed that UFW is active, the simplest and safest way to allow incoming traffic on port 8080 is to add a firewall rule using UFW.

sudo ufw allow 8080/tcp
sudo ufw reload

Check the updated rules:

sudo ufw status

Step 3: Open Port 8080 Using iptables

If you prefer more control over firewall rules, you can open port 8080 using iptables, which allows incoming TCP traffic on the port and ensures it persists after reboot.

sudo iptables -A INPUT -p tcp --dport 8080 -j ACCEPT
sudo iptables-save | sudo tee /etc/iptables/rules.v4

Step 4: Test Port 8080

After opening the port, verify it is accessible. You can use netcat or curl:

nc -zv localhost 8080

Or test from another machine on the network:

curl http://<your-ubuntu-ip>:8080

Step 5: Secure Port 8080

Only open ports that are necessary. If the application does not need external access, limit connections to localhost:

sudo ufw allow from 127.0.0.1 to any port 8080 proto tcp

Share:

More Posts

How to Install Maven on macOS 2025

What you will read?1 Check for Java Installation2 Install Homebrew (If Not Installed)3 Install Maven via Homebrew4 Verify Environment Variables (Optional)5 Create a Sample Maven

How to Use Google SMTP Server

What you will read?1 Step 1: Enable SMTP Access in Gmail2 Step 2: Secure Connection with TLS3 Step 3: Send an Email via SMTP4 Step

how to install wine on RHEL

What you will read?1 Check RHEL version and CPU architecture2 Update system and install base tools3 Verify subscription and enable CodeReady Builder4 Enable EPEL repository5

Subscribe
Notify of
guest
0 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments