# Pull In Stream YouTube, Twitch, free live TV, and games from your own PC to another PC, touchscreen, phone, iPad, or tablet. The host runs Sunshine and [Argon2000’s Moonlight Web fork](https://github.com/Argon2000/moonlight-web-stream-tsla). Viewing devices use a browser. ## 1. Set up the host PC 1. Extract the whole ZIP on the Windows PC. Open **Start-Pull-In.cmd** and choose **First-time setup**. If Python or other tools are missing, the launcher offers to install them. Reopen the launcher and choose **First-time setup** again after installing any requested tools. 2. Follow the prompts to set up your local [Sunshine](https://docs.lizardbyte.dev/projects/sunshine/latest/) login and add the Pull In media shortcuts. If Windows protects the Sunshine folder, close Sunshine, right-click **Start-Pull-In.cmd**, choose **Run as administrator**, then select **Add shortcuts to Sunshine**. Your existing apps are kept and a backup is saved beside `apps.json`. 3. Start Sunshine and Pull In. The first run downloads and builds the player. Keep the launcher window open. In Pull In, go to **Settings → Use this PC → Open Moonlight**. Use the password in the `server/config.json` file shown by the launcher. Keep that file private. 4. In Moonlight, add `127.0.0.1` as the Sunshine PC. Select the PC and enter the displayed PIN on Sunshine’s **PIN** page. Launch Desktop and confirm that you get a picture. Sign in to YouTube, Twitch, or Xbox in the host’s default browser to reuse those accounts in the stream. The next time you want to stream locally, start Sunshine and choose **Start Pull In on this PC**. The player stays installed and the Sunshine pairing carries over. ## 2. Make Pull In reachable from another device ### Safari away from home with one hostname After the local stream works, stop the Pull In launcher and leave Sunshine running. In Moonlight, use the generated password and enable **Settings → Security → 2FA** before configuring public access. 1. Right-click **Start-Pull-In.cmd**, choose **Run as administrator**, then choose **Set up or start Safari away from home**. If prompted to install Caddy, reopen the launcher afterward. Enter the domain or DDNS hostname you want to point to the PC and the public IPv4 from your router’s **Internet** or **WAN** page. Use an address dedicated to this setup if the site you already have needs to stay online. The assistant creates the HTTPS configuration, sets the Moonlight media address, and shows both links. 2. In your DNS provider, point the hostname to your public IPv4. If your DDNS provider already updates that record to your home IP, keep that record. In your router, forward the following ports to the PC’s **LAN IPv4** and label the new rules **Pull In** where possible. Run `ipconfig` on the PC if you need to find it. Save the old value of any DNS entry you change so you can restore it later. | Protocol | Ports | Purpose | | --- | --- | --- | | TCP | `80`, `443` | Caddy certificate setup and the Pull In dashboard | | TCP | `8443` | Moonlight’s HTTPS page | | UDP | `40000–40100` | Moonlight’s video and audio | 3. For automatically reversible Windows Firewall rules, run this menu as administrator and approve **temporary Windows Firewall rules**. Rules apply only to the Caddy and Moonlight streamer programs and the ports above. The launcher removes them on normal exit. Confirm you are ready to start Caddy and both services. 4. On the iPhone, turn off Wi-Fi, open `https://your-hostname` in Safari, and save `https://your-hostname:8443` under **Pull In → Settings**. Open a stream and sign in to Moonlight. The assistant remembers the hostname and IPv4 for the next start. If your public IPv4 changes, choose **Set up or start Safari away from home** again and enter the new address. The direct setup requires a public IPv4 on your router. If your ISP uses CGNAT, contact your ISP about a public IP or use an authenticated HTTPS tunnel with a hosted TURN relay. ### Undo the Windows setup Stop Pull In with Ctrl+C, then choose **7. Undo Pull In setup**. Run the launcher as administrator if it created Windows Firewall rules or wrote to the protected Sunshine folder. - **Undo Safari access** removes any remaining firewall rules created by Pull In, restores the Moonlight network fields Pull In changed, and deletes its Caddy configuration, certificates, and remote setup key. It preserves later edits to those Moonlight fields and offers to uninstall Caddy if recorded as installed by Pull In. - **Remove Pull In's host setup** also removes the recorded Sunshine shortcuts, local player, and Pull In's build caches and settings. It offers to uninstall packages the assistant recorded installing. For Python installed by the launcher, it prints an uninstall command to run after the launcher closes. Software installers manage their own services, drivers, and supporting files. - **Finish in the places you changed by hand.** Delete only your Pull In router forwarding rules and Windows Firewall rules. Restore any prior DNS or DDNS records you changed. Clear the saved Pull In website data on viewing devices and remove any Sunshine pairing you added yourself if you want a full removal. Delete the extracted Pull In folder when you finish. Releases before the undo menu did not record the old Moonlight network fields or installer ownership. The undo screen identifies that case for manual review. Setup shares can be cleared from your browser independently of any Windows removal. ### Existing reverse proxy or private HTTPS If you already have a reverse proxy, point your dashboard address at `127.0.0.1:8765` and your Moonlight address at `127.0.0.1:43780`. The Moonlight proxy needs WebSocket upgrades. The devices also need a network route for Moonlight’s WebRTC media. Start both services with `py -3 moonlight.py launch --origin https://your-dashboard-hostname` and save the Moonlight URL in **Pull In → Settings**. If you use [Tailscale Serve](https://tailscale.com/docs/reference/tailscale-cli/serve), install Tailscale on the host and viewing devices and connect them to the same private network. On the host, run these two commands and complete the HTTPS setup prompt if it appears. ```powershell tailscale serve --bg 8765 tailscale serve --bg --https=8443 43780 ``` Keep the two HTTPS addresses printed by those commands. Stop the local Pull In launcher, then run this from the extracted folder. Replace the example with the dashboard address from the first command and omit the trailing slash. ```powershell py -3 moonlight.py launch --origin https://your-pc.your-network.ts.net ``` The launcher remembers that dashboard address for future starts. On the host, open Pull In at that address. In **Settings**, save the Moonlight address from the second command, including `:8443`, then select **Pair another screen**. ## 3. Connect and watch 1. On the receiving PC, phone, iPad, or tablet, scan the QR from the host or open your Pull In HTTPS link. For private links, join the host's private network first. 2. Select **Save & open Moonlight**. Sign in to Moonlight with the password from the host. Use your browser’s Back button to return to Pull In. 3. Choose **YouTube**, **Twitch**, **Live TV**, or **Games**. Open the viewer. The host opens the selected page or app and sends its screen and audio through Moonlight. In **Settings → View styles**, choose **Original view** for YouTube, Twitch, or Pluto TV’s full website. Choose **Pull In view** for the host’s simpler video search, channel finder, or curated live TV. Those views include links to open the full provider on the host. Games offers the original Moonlight library or a Pull In page with shortcuts to the game library, host desktop, and Xbox Remote Play. Pull In saves view choices on the device where you change them. Tap or drag in the Moonlight viewer on a touchscreen. For controls that work better as a pointer, open the player sidebar and choose **Point and Drag** under the touch settings. To play with a gamepad, connect it to the viewing device and press a button. To use a separate device for input, open Moonlight there and choose **Attach Input Only** from the active app’s menu. ## Player build tools If Windows Package Manager is unavailable, install [Python 3.10 or later](https://www.python.org/downloads/), [Sunshine](https://docs.lizardbyte.dev/projects/sunshine/latest/), [Git](https://git-scm.com/install/), [Node.js with npm](https://nodejs.org/en/download), and [rustup](https://rustup.rs/). If you need to install the HTTPS proxy manually, see [Caddy's installation guide](https://caddyserver.com/docs/install). The launcher installs the Rust nightly version needed by the selected fork. A first build needs internet access for the source and dependencies. **Windows x64.** Install [MSYS2](https://www.msys2.org/) in its default folder. Update it following its setup instructions, then run this in the **MSYS2 MINGW64** terminal. Reopen the Pull In launcher afterward so it can see your installed tools. ```sh pacman -S --needed mingw-w64-x86_64-gcc mingw-w64-x86_64-binutils mingw-w64-x86_64-cmake mingw-w64-x86_64-make mingw-w64-x86_64-clang mingw-w64-x86_64-openssl ``` Set `PULL_IN_MINGW64` to the `mingw64` folder if MSYS2 is installed elsewhere. To use a non-default Sunshine app list, run `py -3 moonlight.py shortcuts "C:\path\to\apps.json"`. The Windows build uses OpenSSL from this MINGW64 folder and compatible Rust bindings. If an older launcher stopped at `openssl-sys` with a missing Perl error or an OpenSSL version mismatch, open the updated launcher and choose **2. Start Pull In on this PC**. You can use the MSYS2 tools you already installed. The web player build uses TypeScript and Python's file copy tools. **Mac or Linux.** Install CMake, a C/C++ compiler, Clang/libclang, and the OpenSSL development libraries. Run `python3 moonlight.py shortcuts` with Sunshine closed, restart Sunshine, then run `python3 moonlight.py launch`. Use `python3` in place of `py -3` for the private-network command above. On macOS with Homebrew OpenSSL, set `OPENSSL_DIR` to the prefix returned by `brew --prefix openssl@3`, and set `OPENSSL_STATIC=1` if needed for the native Moonlight library. See the fork’s [Building section](https://github.com/Argon2000/moonlight-web-stream-tsla#building) for the native dependencies. ## View-only screen sharing For a browser-based view-only session, choose **Setup → View-only screen sharing**. On the host, select **Start sharing** in Chrome or Edge and pick a tab, window, or screen. If prompted for a host key, use `screen-sharing-key.txt` in the folder printed by the launcher. Choose **Pair a device** and open its private invite on the viewing device. Select **Pair & watch**. That device can reconnect while capture is active. Use **Revoke** to remove access. If the viewing browser cannot reach the host’s WebRTC candidates directly, the launcher supports your own STUN server through `PULL_IN_STUN_URL` or a TURN server through `PULL_IN_TURN_URL`, `PULL_IN_TURN_USER`, and `PULL_IN_TURN_PASSWORD`. ## If something doesn’t open - **A viewer says it can’t find an app.** Add the Sunshine shortcuts, restart Sunshine, and reload the viewer. - **The QR code doesn’t appear.** Open Pull In at its private HTTPS address and save the private HTTPS address for Moonlight. Loopback addresses such as `127.0.0.1` work on the host itself. - **The screen goes black after the connection.** Check that Sunshine can capture the host display and that the viewing device can reach Moonlight’s WebRTC media path. The default Moonlight range is UDP `40000–40100`. See the fork’s [configuration section](https://github.com/Argon2000/moonlight-web-stream-tsla#config). - **Another stream is active.** The viewer asks before switching. The switch closes the other stream on that host. The two servers listen on loopback by default. Pull In’s QR for adding the Moonlight player contains its address. Provider sessions stay in the host browser, Moonlight sign-in stays in the viewer’s browser, and Sunshine encodes and sends the app through the selected fork’s canvas and audio pipeline.