Running your own Icecast server gives you complete control over your streaming infrastructure—no listener limits imposed by a hosting provider, no monthly subscription fees beyond the VPS cost itself, multiple simultaneous mount points, and full access to server logs and statistics. This guide walks through the complete process of setting up an Icecast 2 server on a Linux VPS, from initial server selection through configuring BroadcastMySelf to connect to your self-hosted stream.
Choosing a VPS Provider and Plan
A VPS (Virtual Private Server) is a virtual machine running on shared physical hardware, giving you your own isolated Linux environment with root access. For Icecast hosting, the key specifications to consider are bandwidth allocation, geographic location, and monthly cost.
Icecast bandwidth usage scales with the number of simultaneous listeners and your stream bitrate. The formula is: Simultaneous Listeners × Bitrate (kbps) = Required Bandwidth. For 50 simultaneous listeners at 128 kbps, you need at least 6.4 Mbps of outbound bandwidth. Most VPS plans include 1–5 TB of monthly data transfer, which is sufficient for small to medium stations.
Recommended VPS providers for Icecast hosting include DigitalOcean ($6/month for the basic Droplet), Vultr ($6/month), Linode/Akamai Cloud, and AWS Lightsail ($5/month). For most new stations, the $6/month entry-level plan with 1 GB RAM and 1 TB monthly transfer is more than adequate. Choose the datacenter region closest to where you broadcast from—this minimizes your streaming latency.
Initial Server Setup
Once you have provisioned a VPS running Ubuntu 22.04 LTS (the recommended distribution for stability and long-term support), connect to it via SSH from your terminal:
First, update the system packages to ensure you have the latest security patches:
Create a non-root user for daily operations (good security practice):
usermod -aG sudo broadcaster
Installing Icecast 2
Icecast 2 is available directly from Ubuntu's package repositories. Install it with:
During installation, Ubuntu may present a configuration dialog. If it does, accept the prompts for now—you will configure the server properly through the XML configuration file afterward. Once installed, the Icecast configuration file is located at /etc/icecast2/icecast.xml. Open it with a text editor:
Configuring icecast.xml
The icecast.xml file contains all the settings that control how your server operates. The key sections to configure are:
Authentication passwords — Icecast uses three separate passwords for different access levels:
<source-password>YourSourcePassword</source-password>
<relay-password>YourRelayPassword</relay-password>
<admin-user>admin</admin-user>
<admin-password>YourAdminPassword</admin-password>
</authentication>
The source password is what you enter in BroadcastMySelf. Choose a strong, unique password—this is the credential that allows software to send a stream to your server. The admin password grants access to the Icecast web admin panel at http://yourserver:8000/admin/.
Listener limits — Set the maximum number of simultaneous connections:
<clients>100</clients>
<sources>2</sources>
<queue-size>524288</queue-size>
<client-timeout>30</client-timeout>
<header-timeout>15</header-timeout>
<source-timeout>10</source-timeout>
<burst-size>65536</burst-size>
</limits>
Listen socket — The port Icecast listens on for connections:
<port>8000</port>
</listen-socket>
Port 8000 is the Icecast default and widely recognized. If your hosting provider or network environment blocks port 8000, you can also add a second listener on port 80 or 443 for maximum compatibility.
Server hostname — Set this to your server's IP address or domain name:
Configuring the Firewall
By default, Ubuntu's UFW (Uncomplicated Firewall) may block incoming connections on port 8000. Open the port with:
ufw allow 22/tcp
ufw enable
The ufw allow 22/tcp command ensures your SSH connection remains accessible after enabling the firewall. Verify the rules with ufw status.
Starting and Enabling Icecast
Start the Icecast service and configure it to start automatically on server boot:
systemctl enable icecast2
Check that it is running:
You should see "active (running)" in the output. Open a browser and navigate to http://your_server_ip:8000 to confirm the Icecast web interface loads. The default Icecast welcome page confirms your server is operational.
Connecting BroadcastMySelf to Your Server
Now configure BroadcastMySelf to connect to your self-hosted Icecast server. In the app, go to Settings > Connection and enter:
- Server Type: Icecast 2
- Host: Your VPS IP address or domain name (e.g., 192.168.1.1 or stream.yourstation.com)
- Port: 8000
- Mount Point: /live (you can use any path starting with /)
- Password: The source-password you set in icecast.xml
Tap Test Connection. If successful, you will see a confirmation. Your stream URL will be http://your_server_ip:8000/live — share this with listeners or submit it to radio directories.
Setting Up Multiple Mount Points
One of Icecast's most powerful features is the ability to serve multiple simultaneous streams on the same port. For example, a high-quality stream for Wi-Fi listeners and a low-bitrate stream for mobile data listeners. In icecast.xml, add mount point configurations:
<mount-name>/live</mount-name>
<max-listeners>50</max-listeners>
<stream-name>My Station Live</stream-name>
<stream-description>High quality live stream</stream-description>
<genre>Electronic</genre>
</mount>
<mount type="normal">
<mount-name>/mobile</mount-name>
<max-listeners>100</max-listeners>
<stream-name>My Station Mobile</stream-name>
<stream-description>Low bandwidth mobile stream</stream-description>
</mount>
Reload the Icecast configuration after any changes with systemctl reload icecast2.
Monitoring Your Server
The Icecast admin panel at http://yourserver:8000/admin/ (login with your admin credentials) shows real-time listener counts per mount point, current stream metadata, and connected sources. For more detailed analytics, the Icecast log files are located at /var/log/icecast2/ — the access.log file records every listener connection with timestamp, IP address, and duration.
For production servers, consider setting up logrotate to prevent log files from growing indefinitely, and monitoring tools like Prometheus with the Icecast exporter plugin for long-term analytics visualization.
Security Considerations
Running a public server requires attention to basic security practices. Always use strong, unique passwords for your source, relay, and admin credentials. Keep the Icecast package updated (apt upgrade icecast2) to receive security patches. Consider running Icecast behind an Nginx reverse proxy on port 443 with a Let's Encrypt SSL certificate—this encrypts the connection between your broadcaster and server, and between the server and your listeners.
Conclusion
Self-hosting an Icecast server on a VPS takes about 30–60 minutes to complete and gives you a streaming infrastructure with no listener limits and no ongoing hosting fees beyond the VPS cost. For stations that have grown beyond the limits of managed hosting plans, or broadcasters who want complete control over their streaming infrastructure, self-hosting is the clear next step. Combined with BroadcastMySelf on Android, you have a complete end-to-end broadcasting system that runs entirely on infrastructure you control.