How to Claim Your Plex Server
After you install Plex Media Server and then have it start for the first time, you will get a message that the server is unclaimed. This means that the server is not associated with any Plex account.
When a Plex server is not associated with an account, the following message will appear in the server settings:
This server is unclaimed and not secure Claiming this server will associate it with your Plex account. This helps your devices find each other and helps keep your media safe.
You will also see this message if you reset your Plex password, and then check the checkbox stating that all devices associated with your Plex account will be signed out. This option will not only sign out of client devices but also any servers associated with your account.
The above message will also be displayed if you remove a server from Plex from your account.
Depending on how your Plex server is configured, different methods can be used to claim your Plex server. The steps associated with each method are detailed below.
There are three ways you can claim your Plex server:
- Using the local Plex Web App: This is the easiest method and should be tried first.
- Manually making the changes: This requires sending a request to Plex for a claim code and using a terminal to manually claim the server.
- Using the API: This method uses the Plex API.
Each method is outlined in the following sections.
Access the local Plex Web App
You claim, or reclaim your Plex server through the local version of the Plex Web App. How you access the Web App is dependent on how Plex is configured. This section will list the various ways you can access the local Web App.
On the Plex server
From the Plex server, you can use the following steps:
- Open your Web browser.
- Enter
http://localhost:32400/web
orhttp://127.0.0.1:32400/web
into the address bar. - The Plex Web App will load in the Web browser.
On the same network
If you are on the same network as your Plex server, you can do the following:
- Open your Web browser.
- Enter
http://{plex_server_ip_address}:32400/web
into the address bar. - The Plex Web App will load in the Web browser.
On a different network
If your Plex server is on a different network, then you will need to set up an SSH tunnel. This will allow you to access your Plex server as if it were local.
Linux or OS X
If your Plex server is running on Linux or a Mac, you can connect to your Plex Web App through an SSH tunnel using the following steps:
- Open a terminal window.
- In the terminal window enter:
{plex_server_ip_address} - L 8888:localhost:32400
. - Open your Web browser.
- Enter
http://localhost:32400/web
into the address bar.
Windows
If your Plex server is running on Windows, you will need to use an application like Putty to create the SSH tunnel.
You would use the following information to setup Putty:
Gateway | Source Port | Destination |
---|---|---|
{plex_server_ip_address} | 8888 | localhost:32400 |
Claim your Plex server
Once you have connected to the local Plex Web App, you can now claim your server. To claim your Plex server, use the following steps:
- From the local Plex Web App, click the Settings icon.
- From the menu on the left, click the General option under the Settings section.
- Click the CLAIM SERVER button on the right.
- You will be asked to sign in to complete the process of claiming your server.
After completing the above steps, you should now have claimed your Plex server. At this point, you will have a new Plex Authentication Token generated for the server, which will be used to make requests to plex.tv.
Claiming your server manually
If you are having issues claiming your server using the steps outlined in the previous section, you can try to claim your server manually.
The manual process involves performing the steps Plex would do when you use the Web page, but you perform the tasks instead of Plex.
To manually claim your Plex server, use the following steps:
- Stop the Plex Media server from running.
- From the Plex advanced settings, delete the
PlexOnlineToken
value, and keep the name. - Also from the hidden settings, copy the
ProcessedMachineIdentifier
value as it will be used to generate a claim token. - Open a Web browser and log in with your Plex account.
- After logging in, go to
https://www.plex.tv/claim
to generate a claim token. Copy this token. - From a terminal window, run the following command:
curl -X POST -s -H "X-Plex-Client-Identifier: {processed_machine_identifier}" "https://plex.tv/api/claim/exchange?token={claim_token}"
Replace
{processed_machine_identifier}
with the value from theProcessedMachineIdentifier
setting, and{claim_token}
with the claim token from the Web page. At the bottom of the response should be the following values:
username
email
authentication-token
Each value will need to be copied into the Plex advanced settings with the following key names:
- PlexOnlineMail:
email
- PlexOnlineUsername:
username
- PlexOnlineToken:
authentication-token
- AcceptedEULA:
1
- PublishServerOnPlexOnlineKey:
1
- Restart Plex Media Server and you should now have the server claimed to your account.
Claim your Plex server using the API
You can claim your server programmatically using the plex.tv API. While the Plex Web App method is the recommended way of claiming your server, there is the option of using the API.
To use the API to claim your Plex server, use the following steps:
- Call the plex.tv claim token API endpoint to generate a new claim token:
https://plex.tv/api/claim/token?X-Plex-Token={plex_token}
- From your Plex server, submit the claim request:
http://{plex_server_ip_address}:32400/myplex/claim?token={claim_token}
The Plex Token that is used in the plex.tv request must be either the administrative token associated with your account or a device token. A token associated with a managed user will return a 401 status code.
Once the requests are made, you will get one of the following response status codes indicating the result:
HTTP Code | Description |
---|---|
200 | Success. The request was successful. |
401 | Unauthorized. The Plex token used to make the request is not authorized to remove the server. |