# Create Plex Server as a service (Mac)

**URL:** <https://forums.plex.tv/t/create-plex-server-as-a-service-mac/21101>\
**Category:** Feature Suggestions\
**Created:** [September 6, 2012, 2:45pm UTC](https://forums.plex.tv/t/create-plex-server-as-a-service-mac/21101 "2012-09-06T14:45:56Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![iYom](https://avatars.discourse-cdn.com/v4/letter/i/22d042/32.png) [@iYom](https://forums.plex.tv/u/iYom)\
**Post date:** [September 6, 2012, 2:45pm UTC](https://forums.plex.tv/t/create-plex-server-as-a-service-mac/21101/1 "2012-09-06T14:45:56Z")

</div>

Headless server application...
On Mac, (like discused for Windows on the topic "Create Plex Server as a service (Windows)" )  
It's necessary to by loged to have a working Plex Media Server...  
  
We have nows a very good Web GUI... so...

---

<div class="post-metadata">

**Author:** ![Zephyr\_blues](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/zephyr_blues/32/1117_2.png) [@Zephyr\_blues](https://forums.plex.tv/u/Zephyr_blues)\
**Post date:** [November 21, 2012, 11:14pm UTC](https://forums.plex.tv/t/create-plex-server-as-a-service-mac/21101/2 "2012-11-21T23:14:20Z")

</div>

I’d love this one… asked around for this one long ago. Never a surprise when you’re not logged in…

---

<div class="post-metadata">

**Author:** ![a\_ndy](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/a_ndy/32/4338_2.png) [@a\_ndy](https://forums.plex.tv/u/a_ndy)\
**Post date:** [November 22, 2012, 12:10am UTC](https://forums.plex.tv/t/create-plex-server-as-a-service-mac/21101/3 "2012-11-22T00:10:53Z")

</div>

+1

---

<div class="post-metadata">

**Author:** ![roger6106](https://avatars.discourse-cdn.com/v4/letter/r/edb3f5/32.png) [@roger6106](https://forums.plex.tv/u/roger6106)\
**Post date:** [April 29, 2019, 12:50pm UTC](https://forums.plex.tv/t/create-plex-server-as-a-service-mac/21101/4 "2019-04-29T12:50:13Z")

</div>

I’ve been looking into how to do this, and I’m surprised it is not supported by Plex.

I attempted to make it work modifying the LaunchDaemons, but I get the error: `FAILED TO establish the default connection to the WindowServer`

My current workaround is to:

1. Enable fast user switching on MacOS.
2. Create a special Plex user.
3. Set the computer to autologin to the Plex user on startup.
4. Trigger a LaunchAgent script on login to that user that locks the account.

This mostly works, but it does mean:

1. Added resources are used to run a whole other login instead of just the server.
2. To shutdown or restart the machine, an admin username and password are required since multiple accounts are logged in.

---

<div class="post-metadata">

**Author:** ![tom80H](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/tom80h/32/19753_2.png) [@tom80H](https://forums.plex.tv/u/tom80H)\
**Post date:** [July 9, 2021, 11:15pm UTC](https://forums.plex.tv/t/create-plex-server-as-a-service-mac/21101/5 "2021-07-09T23:15:27Z")

</div>

2021 clean-up: duplicate

> [@Run Plex Media Server on Mac as a Daemon](https://forums.plex.tv/t/run-plex-media-server-on-mac-as-a-daemon/115540):
>
> I’d like the feature on my Mac to run Plex Media Server as a Daemon with launchd, so that it can run even if no one is logged in.
