Change Plex Media Server port away from 32400

I would like to change the port that Plex Media Server runs/listens on. I’m not trying to resolve a port forwarding issue. I need to change the listening port away from 32400 if at all possible?

1 Like

@denose said:
I would like to change the port that Plex Media Server runs/listens on. I’m not trying to resolve a port forwarding issue. I need to change the listening port away from 32400 if at all possible?

do it via the plex web interface

@starbetrayer said:
do it via the plex web interface

Thanks for responding. Are you referring to Settings > Server > Remote Access > Manually Specify Port? This doesn’t work for my situation unfortunately. I can do it that way until I turn on VPN. My VPN the has it’s own port forwarding except that you can not change the ports or redirect them when traffic comes through. Due to this I would like to run Plex itself on the compatible ports, not 32400.
I also had a look at the Registry key (Windows) mentioned by some but this looks to be the same as the web interface setting I mentioned.

@denose said:
I also had a look at the Registry key (Windows) mentioned by some but this looks to be the same as the web interface setting I mentioned.

yes, correct.
what VPN client do you use ?

The Local TCP Port number cannot be changed - it has to be 32400.
Only the remote port can be changed

@starbetrayer said:
what VPN client do you use ?

I was thinking maybe it can’t be changed :-S
I am using iVPN running on the host, not router. I might need to switch to a VPN provider that allows port forwarding assignment rather than fixed. You don’t happen to have suggestions?

@denose said:
I am using iVPN running on the host, not router. I might need to switch to a VPN provider that allows port forwarding assignment rather than fixed. You don’t happen to have suggestions?

I do not use a VPN but I remember seeing subjects about it

@sa2000 do you remember the name of the VPN supplier that was suggested ?

@starbetrayer said:
sa2000 do you remember the name of the VPN supplier that was suggested ?

This is the one i bookmarked https://forums.plex.tv/discussion/comment/942326/#Comment_942326

I do this as it is the only way I can access my Server behind a double NAT situation. I use AirVPN and setup a port forward, they dictate the port number so you change the external port in Plex Server Settings > Server > Remote Access > Manually Specify Port and that points to internal Plex port 32400. Leave it a few minutes and boom green all the way and Plex is accessible outside your network. Haven’t suffered any speed slow downs and it just works 100% of the time. Can’t recommend it enough!

1 Like

ive 2 plex servers running so needed to change one so that external traffic could hit appropriate server. I have achieved this with an iptable NAT on the server its self to translate from my external port 44444 to 32400 . I have enabled the external port in firewall on my router and directed it to the server ip , traffic hits the server on the external remote port 44444 and is translated internally before it hits the server as the local 32400 port
see example

1 Like

Sorry to necro and old thread, but I have been fighting with this for over a month now. Blamed my ISP and had them ship a new router, even. For some reason, the port redirect wouldn’t work. On Server #1, I forwarded 32400 from my WAN IP to my server IP. For Server #2, I tried redirecting TCP 32401 to TCP 32400, with 32401 forwarded in my router to my server #2 IP, but it just WOULD NOT WORK. Tried tinkering with all firewall rules, with my Plex settings, etc. The final fix was to use iptables to resolve it. I am running Plex on two QNAP NAS boxes and on Server #2, I used the command: iptables -t nat -I PREROUTING --src 0/0 --dst <server#2 IP> -p tcp --dport 32401 -j REDIRECT --to-ports 32400 . That FINALLY resolved my issue! Thanks Andy_R!!

well some routers are very restricted in what they allow you to do when creating a Port Forward rule. But most routers do allow for you to have a different port number for WAN from that on LAN. The router you would need is one that allows you to do that

So for example
PMS1
Port Forrward WAN TCP Port 32410 to LAN TCP Port 32400 and forward to PMS1 Local IP

PMS2
Port Forrward WAN TCP Port 32420 to LAN TCP Port 32400 and forward to PMS2 Local IP

So if you do not have that option it is the fault of your ISP not providing you with a good router

(Be careful with any use of tcp port 32401 on the server because this tcp port is reserved for internal use by Plex Media Server for loopback/ localhost for Plex Relay)

Since i’m dealing with this right now i’m going to post my solution here for anyone wanting to do something like this. There is already a solution using IP tables but in my case I setup an Apache reverse proxy in front of Plex.

I use the following virtual host configuration

<VirtualHost *:80>
    ServerName plex.hwse.ca
    ProxyPreserveHost On
    ProxyPass / http://plex:32400/
    ProxyPassReverse / http://plex:32400/
</VirtualHost>

The ServerName value is a domain I bought and use for various things internally.