Run two prerecorded YouTube Live loops from one VPS by starting two independent FFmpeg processes, each with its own media input, stream key, output settings, log, and restart policy. Use the RTMPS endpoint and key shown for each stream in YouTube Live Control Room, pace file playback with -re, and repeat it with -stream_loop -1. Before leaving them unattended, test both processes together: the VPS must sustain their combined upload bitrate, and any re-encoding must fit its actual CPU capacity.
What you need before starting
- A Linux VPS with enough sustained outbound network capacity for both streams, plus room for overhead and bitrate variation.
- Two local video files accessible to the account that will run FFmpeg. Check each file’s video and audio codecs, resolution, frame rate, and whether it has an audio track.
- FFmpeg installed on the VPS. Confirm the executable is available with
ffmpeg -version. - Two YouTube Live destinations and their individual stream keys from Live Control Room.
- A process supervisor or service manager, separate logs, and a way to check each stream’s process and YouTube stream health.
There is no universal VPS CPU or memory specification for this setup. Requirements depend on whether FFmpeg copies compatible streams or encodes them, the codecs, resolution, frame rate, filters, and the VPS’s measured performance. No published provider benchmark establishes that a particular low-cost server can sustain two encodes.
Configure each YouTube destination
- In YouTube Studio, open Create > Go live to reach Live Control Room, then create or select the first stream.
- Copy the stream URL and stream key shown for that stream. Repeat for the second stream. Each FFmpeg process must send to its own destination and use its corresponding key.
- Prefer the RTMPS endpoint provided by Live Control Room. YouTube recommends RTMPS because it encrypts the connection using TLS/SSL. Do not assume an RTMP URL and RTMPS URL are interchangeable; use the exact endpoint shown for the stream.
- Protect each key like a password. Do not put it in a public script, commit it to a repository, or share unredacted command lines and logs. If a key is compromised, a channel owner or manager can reset it in Live Control Room; update the matching FFmpeg configuration afterward.
Choose copy or re-encode
Stream copy
Copying avoids the CPU cost of video and audio encoding, but it is appropriate only when the source codecs and output/container requirements are compatible with the destination. Inspect the file first; do not assume an MP4 is compatible merely because of its filename or container.
A basic inspection command is ffprobe -hide_banner /path/to/stream-one.mp4. Review the reported video and audio codecs, dimensions, frame rate, and audio presence before deciding. If the media is compatible, a command can use -c copy instead of separate video and audio encoders; test the actual output in YouTube Live Control Room.
Re-encode
Encoding gives control over output codec, bitrate, scaling, and frame rate, but each of the two processes adds its own encoding workload. The example below uses H.264 video and AAC audio. Its 5 Mbps video setting is an illustration corresponding to YouTube’s recommended H.264 rate for 720p30, not a universal setting and not evidence that your source is 720p30. Set the target to match your intended resolution and frame rate.
#1 Best Overall
- Read Before You Buy — No Video Output: These adapters support charging and USB 2.0 data transfer, but cannot transmit video signals. Except for standard USB webcams (which use USB data only), they are not compatible with HDMI/DisplayPort cables, video-capable USB-C hubs, or docking stations with video output.
- Convert USB-A Ports to USB-C: Designed to connect USB-C earphones, cables, flash drives, card readers, and other USB-C accessories to standard USB-A ports. Plug-and-play with no drivers or software required.
- Aluminum Alloy Housing: Built with a sturdy aluminum alloy shell that aids in heat dissipation and protects against daily wear and scratches. Designed to maintain a stable and secure connection.
- Compact & Travel-Friendly: The ultra-compact design allows the adapter to stay plugged into your device without blocking adjacent ports or adding bulk, reducing wear and tear on your original USB ports.
- 12-Month Warranty: Backed by a 12-month manufacturer warranty for peace of mind. Designed to meet strict quality control standards for reliable everyday performance.
Start the first looping stream
For a compatible local file, this representative re-encoding command shows the key structure. Replace the example path and the quoted RTMPS destination with the exact endpoint and key from Live Control Room. Keep the destination private.
ffmpeg -re -stream_loop -1 -i /path/to/stream-one.mp4
-c:v libx264 -preset veryfast -b:v 5M -maxrate 5M -bufsize 10M
-g 60 -keyint_min 60 -sc_threshold 0
-c:a aac -b:a 128k -ar 44100
-f flv 'rtmps://INGEST_URL/STREAM_KEY'
-rereads a file at its native rate for live-style output rather than sending it as fast as possible.-stream_loop -1repeats the input indefinitely.-g 60 -keyint_min 60set a 60-frame keyframe interval in this example. That is two seconds only at 30 fps; adjust the interval to the actual output frame rate.-f flvselects the output format used by FFmpeg’s documented RTMP example.- Options are order-sensitive: input options belong before the relevant
-i, and output options before that output destination.
This is a command structure, not a tested universal preset. If the file has no audio, remove or adjust the audio options as needed. Confirm that the chosen codec, frame rate, bitrate, and keyframe interval match the media and YouTube’s current guidance before relying on the stream.
Rank #2
- 5-in-1 USB-C Hub: Experience comprehensive connectivity featuring a Power Delivery input, two USB-A 2.0 ports, a USB-A 3.0 port, and an HDMI port. (Note: The USB-C power delivery input port is only for connecting an external wall charger to power your laptop and cannot power peripheral devices.)
- 90W Pass-Through Charging: Achieve optimal charging with 90W pass-through power to your laptop, supported by a total input of 100W, with the hub reserving 10W for operational efficiency. (Note: Wall charger not included.)
- Quick Data Transfers: Accelerate your productivity with rapid data transfers using a high-speed 5Gbps USB 3.0 port and two 480Mbps USB 2.0 ports.
- 4K HDMI Display: Enhance your visual experience with a hub capable of delivering 4K resolution at 30Hz in both mirror and extend modes. Please note that this hub is compatible with MacBook (macOS 12 and newer), Windows 10 and 11, ChromeOS, and laptops equipped with DP Alt Mode and Power Delivery. Note: This device is not compatible with Linux.
- What You Get: Anker USB-C Hub (5-in-1, 4K HDMI), welcome guide, 18-month warranty, and our friendly customer service.
Start the second stream independently
Launch a second FFmpeg process with the other file and its own stream key. Keep the arguments, process, log, and restart behavior separate so a failure or configuration change in one stream does not silently affect the other.
ffmpeg -re -stream_loop -1 -i /path/to/stream-two.mp4
-c:v libx264 -preset veryfast -b:v 5M -maxrate 5M -bufsize 10M
-g 60 -keyint_min 60 -sc_threshold 0
-c:a aac -b:a 128k -ar 44100
-f flv 'rtmps://SECOND_INGEST_URL/SECOND_STREAM_KEY'
For manual testing, run each command in its own terminal session and verify both appear as incoming streams in Live Control Room. For unattended operation, create one service or supervised process per stream, with distinct configuration and log files. Configure the supervisor to restart a process that exits, and alert on a stopped process or unhealthy YouTube stream. Exact service-manager syntax depends on your Linux distribution and deployment; do not treat a process left in a shell as a durable restart policy.
Rank #3
- Sleek 7-in-1 USB-C Hub: Features an HDMI port, two USB-A 3.0 ports, and a USB-C data port, each providing 5Gbps transfer speeds. It also includes a USB-C PD input port for charging up to 100W and dual SD and TF card slots, all in a compact design.
- Flawless 4K@60Hz Video with HDMI: Delivers exceptional clarity and smoothness with its 4K@60Hz HDMI port, making it ideal for high-definition presentations and entertainment. (Note: Only the HDMI port supports video projection; the USB-C port is for data transfer only.)
- Double Up on Efficiency: The two USB-A 3.0 ports and a USB-C port support a fast 5Gbps data rate, significantly boosting your transfer speeds and improving productivity.
- Fast and Reliable 85W Charging: Offers high-capacity, speedy charging for laptops up to 85W, so you spend less time tethered to an outlet and more time being productive.
- What You Get: Anker USB-C Hub (7-in-1), welcome guide, 18-month warranty, and our friendly customer service.
Match YouTube’s encoder settings
YouTube’s current encoder guidance, accessed 2026-10-03, lists H.264, H.265/HEVC, and AV1 video for RTMP/RTMPS ingest, recommends CBR, supports frame rates up to 60 fps, and recommends a two-second keyframe interval that should not exceed four seconds. Its bitrate recommendations vary by codec, resolution, and frame rate.
| H.264 output | YouTube minimum video bitrate | YouTube recommended video bitrate |
|---|---|---|
| 720p30 | 3 Mbps | 8 Mbps |
| 1080p30 | 5 Mbps | 14 Mbps |
| 1080p60 | 6 Mbps | 17 Mbps |
YouTube’s stereo audio recommendation is 128 Kbps. These are YouTube’s published encoder recommendations, not measured VPS network totals. Allow for transport overhead and bitrate variation rather than treating the configured video and audio values as an exact measurement of the traffic on the wire.
Rank #4
- Dual Converters, Infinite Potential:Includes 2× USB C male to USB A female adapters and 2× USB A male to USB C female adapters. Perfect for a wide range of uses—tablets with Bluetooth keyboards, expand USB ports on macbook, and more. Two different converters for all your daily needs
- Next-Level 10Gbps & 3A Charging: No more slow 480Mbps, this usb to usb c adapter has a transfer speed of up to 10Gbps, allowing you to do more transferring in less time. This usb adapter fits both USB A and USB C charger, supporting up to 3A fast charging
- Upgraded Exquisite Craftsmanship: With an aluminum alloy housing and metal connector, the usbc to usb adapter is extremely durable and sturdy. Rigorously tested to withstand more than 10,000 times of plugging and unplugging, ensuring long-lasting performance
- Broad Compatible: The usb c to usb adapter widely supports all USB C/ USB A devices like laptops, tablets, cellphones, car chargers, and phone chargers. Such as compatible with MacBook Pro/Air 2023/2022, Thunderbolt 4/3 Devices,Apple MagSafe Watch 9/8/7/SE/Ultra, iPad Pro 2022/2021, Samsung Galaxy S23/S20/S10, and iPhone 17/16/15 Pro. Plug and play
- Please Note: To reach 10Gbps speed, keep the cable under 3.3 ft. For USB A Male to USB C adapters, try flipping the USB C connector. USB C Male to USB A adapters support bidirectional 10Gbps transfer within 3.3 ft
For example, at 30 fps, a 60-frame GOP is two seconds; at 60 fps, it is one second. Set GOP length to the intended interval at the actual frame rate, and keep the interval within YouTube’s guidance. A fixed keyframe interval and CBR configuration help align the output with the recommended settings.
The Tool Desk
Outbyte PC Repair FREEClear out junk files and repair common Windows errorsFree Scan →Outbyte Driver Updater FREEFix the driver behind crashes, sound loss and screen glitchesFind Drivers →Plan capacity for two simultaneous outputs
Add the configured outgoing bitrates for both streams to estimate sustained upload demand, then reserve headroom. YouTube says the total stream bitrate cannot exceed available upload bandwidth and recommends 20% upload headroom. Applying that reserve to two independent outputs is a planning inference, not a YouTube-published rule specifically for two separate streams.
Best Value
- 5-in-1 Connectivity: Equipped with a 4K HDMI port, a 5 Gbps USB-C data port, two 5 Gbps USB-A ports, and a USB C 100W PD-IN port. Note: The USB C 100W PD-IN port supports only charging and does not support data transfer devices such as headphones or speakers.
- Powerful Pass-Through Charging: Supports up to 85W pass-through charging so you can power up your laptop while you use the hub. Note: Pass-through charging requires a charger (not included). Note: To achieve full power for iPad, we recommend using a 45W wall charger.
- Transfer Files in Seconds: Move files to and from your laptop at speeds of up to 5 Gbps via the USB-C and USB-A data ports. Note: The USB C 5Gbps Data port does not support video output.
- HD Display: Connect to the HDMI port to stream or mirror content to an external monitor in resolutions of up to 4K@30Hz. Note: The USB-C ports do not support video output.
- What You Get: Anker 332 USB-C Hub (5-in-1), welcome guide, our worry-free 18-month warranty, and friendly customer service.
- Estimate each stream’s target video and audio bitrate, accounting for the chosen codec and output settings.
- Add the two streams’ configured rates to estimate aggregate demand. Leave capacity above that estimate for overhead and variation.
- Check the VPS provider’s outbound capacity and test sustained throughput from the server’s region; a nominal port speed alone does not prove the server can sustain the workload.
- Run both processes together and monitor CPU, memory, network throughput, dropped frames, and YouTube stream health. Include other VPS services and any scaling or filter workload in the test.
- If both processes encode, repeat the test with the intended preset and settings. A successful single-stream test does not establish that two simultaneous encodes will work.
Make failures visible and recoverable
FFmpeg documents reconnect options for certain protocols, including retries, reconnecting on network errors, and delay limits. Their behavior depends on the protocol and failure. They do not guarantee recovery from every RTMP/RTMPS disconnect or YouTube-side problem.
- Give each process its own log so you can identify which stream failed and inspect the relevant error.
- Use a process supervisor to restart an exited FFmpeg process, while monitoring whether YouTube actually receives a healthy feed after restart.
- Test failure and recovery behavior before unattended use. Confirm that the stream returns in Live Control Room rather than relying only on a running process.
- Test with audio and moving video similar to the real content, and check YouTube’s stream-health messages before considering the setup ready.
Plan long loops around YouTube’s archive and DVR behavior
YouTube says streams under 12 hours are automatically archived. Separately, DVR rewind may be limited or unavailable for streams longer than 12 hours. DVR concerns pausing, rewinding, and resuming during a live stream; archive availability is a distinct behavior. Check current channel settings and YouTube Help if replay or live rewind is important to your audience.
Check copyright and reused-content risks
A technical loop does not grant permission to rebroadcast its contents. Use media you own or are licensed to stream, and check that the license covers YouTube live broadcasts and any music, artwork, gameplay footage, or other material embedded in the recording. YouTube’s copyright rules and channel monetization decisions are separate from whether FFmpeg can deliver a stable feed; repeated or minimally changed material may also raise reused-content concerns. Review YouTube’s current policies for your content and channel before scheduling a continuous loop.
Troubleshoot common failures
| Symptom | Likely cause | What to check |
|---|---|---|
| YouTube receives no feed | Wrong stream URL or key, mismatched key and destination, blocked outbound connection, or incorrect protocol endpoint. | Copy the exact RTMPS URL and matching key from Live Control Room; verify outbound connectivity and inspect the FFmpeg log for connection errors. |
| One stream works but the other drops frames or disconnects | The combined network load or compute demand exceeds what the VPS sustains. | Run both at once, inspect per-process CPU and aggregate outbound throughput, then lower encoding demand or move to a VPS that passes the simultaneous test. |
| FFmpeg exits after reaching the end of a file | The loop option is missing, misplaced, or the command does not use the intended input. | Place -stream_loop -1 before the relevant input’s -i, then check the log to confirm that file playback repeats. |
| Playback races ahead or the stream ends too quickly | The file is being read faster than real time. | Place -re before the file input so it is read at its native rate. |
| Audio is missing or FFmpeg reports an audio error | The source may have no audio track, or the selected audio options do not fit it. | Inspect the file with ffprobe; remove or adapt audio options if there is no audio, and test the resulting stream. |
| The process is running but YouTube reports an unhealthy stream | Process status alone does not confirm valid, stable video and audio delivery. | Inspect the FFmpeg log, check the actual stream in Live Control Room, and test moving video and audio similar to the intended content. |
| A restarted process can no longer connect | A key may have been reset, the wrong key may be configured, or the failure may be outside FFmpeg’s reconnect handling. | Verify the current key and endpoint in Live Control Room, update the matching process configuration, and test recovery rather than assuming reconnect options cover every failure. |
Or let it run in the cloud
If your goal is a YouTube channel that keeps prerecorded video live without maintaining a VPS and FFmpeg processes, StreamNeo is the #1 alternative to try first: it loops uploaded videos from the cloud, supports any uploaded quality up to 4K 60fps at one flat price per slot, and includes a free first day.
- Upload a recording or build a playlist.
- Add your YouTube stream key once.
- Go live; StreamNeo runs the loop from the cloud, so your computer and home connection do not have to stay on.
Each slot includes one always-on YouTube stream, 10 GB storage per slot pooled across active slots, 24/7 looping and playlists, automatic recovery if YouTube drops the stream, and support from the StreamNeo team. The same product is included on every plan; only the billing period changes. The first day is free with no card, one free day per account. Monthly: $9.99 per month.
Quick Recap
See StreamNeo for details, or start your free day.
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.




