October DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsClean PCRecommendedOne scan can reveal what keeps slowing WindowsLook for cleanup and repair opportunities.Run ScanOctober DealsAmazon USDeal season is back - check today's better picksAmazon US: current deals, useful picks and tech finds.See Picks×
Skip to content
Mountain View desk8 min

How to Set Up a Continuous YouTube Stream on Hetzner Cloud

A practical guide to running a continuous YouTube feed from Hetzner Cloud, from stream keys and VPS setup to encoder settings, testing, supervision, and archive limits.
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

You can keep a YouTube stream running from Hetzner Cloud by creating a VPS, sending an encoded feed from it to YouTube Live, and supervising the encoder so it can recover after a process or server restart. The VPS is only the machine: you still need to configure the media source, encoder, YouTube stream key, network access, and monitoring. This guide uses Ubuntu and FFmpeg as an example approach; the exact command and server size depend on your media and encoding workload.

What you need before starting

  • A YouTube channel eligible to livestream. YouTube currently requires channel verification, no live-streaming restrictions in the previous 90 days, and that the streamer be at least 16. Check the account-specific requirements in YouTube’s live-streaming eligibility guidance.
  • A video or other media source available to the server, and an encoder such as FFmpeg that can read it and send a live feed.
  • A Hetzner Cloud account, a server with public networking, and an SSH key for administration.
  • A stable outbound network path whose capacity exceeds the full stream bitrate. YouTube recommends reserving 20% headroom above the total bitrate.

A stream that is merely running on a VPS is not guaranteed to remain continuously available. Failures can occur in the server, network, encoder, source file, or YouTube ingest path; supervision, alerting, and regular checks are part of operating it.

As an Amazon Associate I earn from qualifying purchases.

Prepare YouTube Live and protect the stream key

  1. In YouTube Studio, select Create → Go Live, then create or select a stream in Live Control Room.
  2. Copy the server URL and stream key shown for the selected stream. The encoder needs both. Treat the key like a password: do not place it in public code, screenshots, or shell history. If it is exposed, reset it in Live Control Room and update the encoder with the replacement.
  3. Choose the ingest protocol and settings in line with YouTube’s current encoder guidance. YouTube recommends RTMPS. Its guidance recommends CBR, a two-second keyframe interval (not more than four seconds), and lists H.264, H.265/HEVC, and AV1 among supported codecs. Consult the current YouTube encoder settings and bitrate table for the resolution and frame rate you intend to send.

Do not assume a server URL or stream key from one event applies to every stream; use the values shown for the stream you have configured.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Create and secure the Hetzner Cloud server

Choose an operating system and location

  1. In Hetzner Console, create a server and select its type, location, OS image, networking, and SSH key. Hetzner offers Ubuntu among its Cloud OS choices. Include the SSH key during creation where possible: Hetzner’s creation guide says adding one later through the Console is not available, although other tooling may add one.
  2. Choose a location based on your operational needs and network path. Hetzner’s documentation recommends closer locations for larger projects, but does not identify a best location for YouTube ingest specifically.
  3. Select a server type based on the actual workload. Sending an already encoded video can use much less CPU than real-time transcoding. There is no universally sufficient plan established for this task; monitor CPU, memory, network, and storage use, then resize or change the approach if the workload requires it.

Hetzner’s Cloud server overview describes server options, but its documentation does not provide a stream-specific benchmark. For a more predictable workload, consider whether shared or dedicated resources suit your needs; neither is automatically the right choice for every feed.

#1 Best Overall
CanaKit Raspberry Pi 5 Starter Kit PRO - Turbine Black (128GB Edition) (8GB RAM)
  • Includes Raspberry Pi 5 with 2.4Ghz 64-bit quad-core CPU (8GB RAM)
  • Includes 128GB Micro SD Card pre-loaded with 64-bit Raspberry Pi OS, USB MicroSD Card Reader
  • CanaKit Turbine Black Case for the Raspberry Pi 5
  • CanaKit Low Noise Bearing System Fan
  • Mega Heat Sink - Black Anodized

Connect over SSH and limit inbound access

  1. Use an SSH client to connect to the server’s public IP address with the private key corresponding to the key selected at creation. Keep the private key secure and restrict access to the server to administrators who need it.
  2. If you use a Hetzner Cloud Firewall, review its rules before attaching it. Hetzner documents that inbound traffic is blocked by default unless allowed, while outbound traffic is permitted by default unless outbound rules are configured.
  3. Allow only the inbound administration access you need, such as SSH from trusted addresses where practical, and retain the outbound connectivity required by the encoder. YouTube receives the feed as an outbound connection from the VPS; do not open inbound media ports simply for YouTube ingest.

Do not pin a presumed YouTube destination IP or open a guessed port range. Ingest endpoints and network requirements should be taken from current YouTube and encoder configuration, not assumed to be fixed.

Configure the encoder and media source

Decide whether to pass through or transcode

If the source is already encoded in a format and bitrate suitable for YouTube, sending it without re-encoding can reduce CPU use. If it does not meet the intended ingest settings, the encoder may need to transcode it, which increases CPU demand and can affect the server size required. The right choice depends on source format, target resolution and frame rate, and the encoder implementation.

Rank #2
CanaKit Raspberry Pi 5 16GB Starter Kit PRO - Turbine Black (128GB Edition) (16GB RAM)
  • Includes Raspberry Pi 5 16GB with 2.4Ghz 64-bit quad-core CPU (16GB RAM)
  • Includes 128GB Micro SD Card pre-loaded with 64-bit Raspberry Pi OS, USB MicroSD Card Reader
  • CanaKit Turbine Black Case for the Raspberry Pi 5
  • CanaKit Low Noise Bearing System Fan
  • Mega Heat Sink - Black Anodized

Install and configure an encoder

Install FFmpeg or another encoder capable of reading your source and publishing to the YouTube server URL using the stream key. Store credentials in a protected configuration or environment mechanism rather than embedding a real key in a public command example. Confirm that your chosen encoder supports the selected protocol and codecs.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

This guide does not prescribe a universal FFmpeg command: looping behavior, timestamp handling, reconnect behavior, and error handling vary with the source and FFmpeg options. Validate a command against the current FFmpeg documentation and test it with your actual file before relying on it. A loop option alone does not establish that the process will reconnect forever after an ingest failure.

Rank #3
CanaKit Raspberry Pi 5 Essentials Starter Kit (4GB RAM)
  • CanaKit Raspberry Pi 5 Essentials Starter Kit

Match YouTube’s ingest requirements

  • Use RTMPS when supported by your encoder and the stream configuration.
  • Set constant bitrate (CBR) where appropriate, and configure a two-second keyframe interval without exceeding four seconds.
  • Choose a codec, resolution, frame rate, and bitrate using YouTube’s current table for the intended output. Higher resolution and frame rate require more upload capacity; transcoding them also requires more server resources.
  • Ensure the source includes the audio and motion characteristics your viewers should receive. A technically connected feed can still have silent audio, frozen video, or an incorrect aspect ratio.

YouTube transcodes incoming live video for playback variants, but that does not make an unstable or noncompliant encoder feed reliable. The feed you send still needs to be valid and consistent.

Test the feed before relying on it

  1. Start the encoder and check the Live Control Room preview before making the stream public or depending on it for a production event.
  2. Verify picture, motion, audio, aspect ratio, and the watch page. Check Live Control Room stream-health messages and address any warnings before unattended operation.
  3. Measure the server’s available upload capacity under realistic conditions. YouTube recommends bandwidth exceeding the total stream bitrate by 20%; if you send primary and backup feeds, include both in the bandwidth budget.
  4. Leave the test running long enough to observe resource use, source looping, and whether timestamps or audio drift become a problem.

Keep it running and detect failures

Use process supervision

Configure a process supervisor so the encoder can start on boot and restart after a crash. A system service manager such as systemd is one possible choice; its unit, restart policy, and configuration are operator decisions, not requirements specified by YouTube or Hetzner. Make sure the restart behavior does not create a tight failure loop if the source file is missing or credentials are invalid.

Rank #4
SANOOV Raspberry Pi 5 4GB Kit, 4GB RAM Single Board Computer with Active Cooler and ABS Case, Complete Raspberry Pi 5 Starter Kit for IoT Robotics Retro Gaming
  • All-in-One Complete Kit: This SANOOV RPi 5 bundle comes with Raspberry Pi 5 4GB RAM single board, active cooler, durable ABS case and screwdriver. No extra parts needed, ready to use right out of the box for beginners and hobbyists
  • Powerful Single Board Computer: Equipped with 4GB RAM and high-performance processor, delivers fast running speed for 4K playback, AI projects, programming and daily computing tasks. SANOOV for raspberry pi 5 4GB is equipped with broadcom 64 quad-core Arm Cortex A76 processor with gigabit ethernet and upgraded with IEEE 802.11ac Wi-Fi, Bluetooth 5.0 dual-band 2.4Ghz and 5Ghz and Power Over Ethernet (POE). Upgrading delivers 2-3 x speed vs Pi 4, redefining the experience
  • Efficient Active Cooler: Effectively lowers operating temperature and prevents performance throttling. Runs quietly even under long-time heavy load, ensures stable operation all day long. SANOOV RPi 5 4GB kit offer an active cooler, which combines an aluminium heatsink with a high-performance PWM fan. Active cooler is fully compatible with the Pi OS, which can effectively reduce the temperature of RPi5 and ensure its good performance during long-term high load operation
  • Sturdy ABS Protective Case: Well-fitted for Raspberry Pi 5 board, can be secured with 4 screws to effectively protect the Pi 5 motherboard from damage, reserves full access to all ports and buttons. SANOOV uses ABS material to produce the case, which has a softer texture and feel. Meanwhile, SANOOV case adopts a layered design for easy disassembly and installation. (Tip: The Case cannot install M.2 HAT Add on Board and Solid State Drive!)
  • Wide Application & Full Compatibility: Seamlessly compatible with official OS and mainstream peripheral accessories for Raspberry Pi 5. Whether you are a beginner, student, electronics hobbyist or professional developer, this all-in-one kit meets your diverse needs. It excels in IoT projects, robotics design, retro gaming devices, home media servers and other DIY creations. Backed by a large global community, you can easily find guides, technical support and shared projects online

Monitor the whole path

Monitor at least the encoder process, CPU and memory use, disk space, network availability, and YouTube stream health. Add alerts that reach someone able to respond. A process supervisor can restart a crashed encoder, but cannot fix a deleted source, exhausted disk, expired or reset key, server outage, blocked outbound route, or YouTube-side problem.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Cloud hosting and supervision can improve recovery, but neither amounts to an uptime guarantee. Test recovery deliberately and document how to replace a compromised key, restart the encoder, and verify the stream after a reboot.

Best Value
RasTech Raspberry Pi 5 8GB Kit with Active Cooler and Pi5 Case
  • 【What you Get】You will get 1*Pi 5 8GB Single Board,1*RasTech Case,1*Active Cooler,1*Screwdriver,1*Installation instructions,12-month free warranty, lifetime service, 24-hour prompt and friendly response.
  • 【More Connectors】There are two USB 3.0 ports(5Gbps simultaneously) and two USB 2.0 ports, which triple total bandwidth ,support any combination of up to two cameras or displays. Peak SD card performance is doubled through support for the SDR104 high-speed mode. It provides a smooth desktop experience for you. Offer Gigabit Ethernet and a PCIe interface, along with dual-band Wi-Fi and Bluetooth 5.0/BLE wireless capability. The RasTech Pi 5 Kit use the new 27W 5.1V 5A USB-C power connector.
  • 【 Support Dual 4Kp60 Display 】Each of the two microHDMI sockets can control a 4K display at 60 Hertz, now support HDR, offering super HD video for media streaming projects. RPi 5 is the first RPi model that comes with a PCI Express port (PCIe 2.0 x1 with 500 MB/s) to attach SSDs (requires separate M.2 HAT).
  • 【 Excellent Chips And Applications】Pi 5 is a full-size Pi computer using silicon built in-house at Pi. The RP1 “southbridge” provides the bulk of the I/O capabilities for Pi 5. Pi 5 is more friendly and convenient in the development of Internet of Things, Web development, machine identification, automatic control and other electronic equipment applications and network.
  • 【 Faster CPU, Better GPU 】 Pi 5 features a Broadcom BCM2712 64-bit quad-core Arm Cortex-A76 processor running at 2.4GHz, it delivers a 2–3× increase in CPU performance relative to RaspberryPi 4. The 800MHz VideoCore VII GPU is compatible to OpenGL ES 3.1 and Vulkan 1.2, substantial uplift in graphics performance. Pi 5 Offers lightning-fast CPU speed, a PCI Express interface, a Real Time Clock (RTC) and a power button and runs significantly cooler than Pi 4.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Choose between a continuous event and shorter scheduled streams

YouTube says streams under 12 hours are automatically archived. That guidance does not establish archive behavior for an indefinitely running event. If preserving replays matters, check YouTube’s current event and archive guidance before deciding whether to split a continuous feed into scheduled shorter events or preserve a separate local recording. Do not assume a 24/7 event will produce an unlimited or complete replay.

Costs and practical trade-offs

Budget for the Hetzner server type, public networking, storage for media, and any additional resources your encoder needs. Hetzner says server prices vary by type, and public IPs are a separate consideration. Its overview lists Primary IPv4 at €0.50 per month excluding VAT, but that figure is from documentation last changed 2022-06-28 and should not be treated as a guaranteed current charge; verify live pricing before provisioning.

Real-time transcoding may require a larger server than sending an already encoded source, while a more capable server does not resolve source-file, network, or YouTube ingest failures. Compare the complete recurring hosting cost with the workload you actually need, then monitor resource use rather than choosing a plan from resolution alone.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Common problems and fixes

YouTube does not receive the stream

  • Confirm the server URL and stream key match the stream selected in Live Control Room.
  • Check that the key has not been reset, copied with extra characters, or exposed and replaced.
  • Verify that the encoder supports the configured protocol and that outbound network access is allowed by server and firewall rules.
  • Use the Live Control Room health status and encoder logs to distinguish an authentication problem from a network or format problem.

The feed connects but YouTube reports poor stream health

  • Check that bitrate and resolution match YouTube’s current table and that the network has the recommended headroom.
  • Verify CBR and keyframe interval settings, then check CPU usage if the server is transcoding.
  • Inspect source playback for intermittent stalls, timestamp issues, missing audio, or a file that does not loop as expected.

The encoder stops and stays stopped

  • Check process logs for invalid input, missing files, permissions, key errors, or resource exhaustion.
  • Confirm the process supervisor is enabled for startup and configured to restart on failure.
  • Check free disk space and whether the server rebooted or lost network access; resolve the underlying fault before restarting repeatedly.

The stream is live but the archive is missing or incomplete

Do not infer archive behavior for a long-running event from YouTube’s automatic-archive guidance for streams under 12 hours. Review the current archive guidance and use shorter scheduled events or a separate recording strategy if replay preservation is essential.

Or let it run in the cloud

If your goal is to keep uploaded video playing on YouTube rather than manage a VPS and encoder, StreamNeo is a cloud service from Yorker Media that loops uploaded videos or playlists to YouTube Live. Upload your video, add your YouTube stream key, and go live. Nothing has to stay on at home; it streams the uploaded quality up to 4K 60fps at one flat price per slot, with no re-encode or quality tiers, and automatically recovers if YouTube drops the stream. The first day is free with no card. Monthly is $9.99 per month. One slot includes one always-on stream, 10 GB storage pooled across active slots, looping and playlists, and StreamNeo team support. StreamNeo is for uploaded videos and YouTube only, not a live camera feed. Start the free day at StreamNeo registration.

Quick Recap

Bestseller No. 1
CanaKit Raspberry Pi 5 Starter Kit PRO - Turbine Black (128GB Edition) (8GB RAM)
CanaKit Raspberry Pi 5 Starter Kit PRO - Turbine Black (128GB Edition) (8GB RAM)
Includes Raspberry Pi 5 with 2.4Ghz 64-bit quad-core CPU (8GB RAM); CanaKit Turbine Black Case for the Raspberry Pi 5
$259.95
Bestseller No. 2
CanaKit Raspberry Pi 5 16GB Starter Kit PRO - Turbine Black (128GB Edition) (16GB RAM)
CanaKit Raspberry Pi 5 16GB Starter Kit PRO - Turbine Black (128GB Edition) (16GB RAM)
Includes Raspberry Pi 5 16GB with 2.4Ghz 64-bit quad-core CPU (16GB RAM); CanaKit Turbine Black Case for the Raspberry Pi 5
$419.99
Bestseller No. 3
CanaKit Raspberry Pi 5 Essentials Starter Kit (4GB RAM)
CanaKit Raspberry Pi 5 Essentials Starter Kit (4GB RAM)
CanaKit Raspberry Pi 5 Essentials Starter Kit
$189.99

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.

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More from the Wire

  1. World desk4 min
    How to Spot an AI Voice Scam Before Sending MoneyDon’t rely on how a caller sounds. Pause, call back through a known number, and verify the emergency with another trusted person before sending money.
  2. Mountain View desk4 min
    Google’s SynthID Detector: How to Check AI-Generated Images, Video and AudioGoogle’s SynthID Detector looks for an embedded watermark in supported images, video and audio. Here is what its results do—and do not—show.
  3. Redmond desk20 min
    How to create a link to File or Folder in Windows 11Windows 11 gives you several ways to point to a file or folder without moving or duplicating it. You can create a desktop shortcut,…
Recommended PC Tool
Recommended PC Tool
Outdated Drivers Are Slowing You DownFree scan - exact matches
PC Slower Than It Used to Be?Free scan - under a minute

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.