Jellyfin Hardware Transcoding with Nvidia Graphics Cards on Unraid

If you’re migrating from Plex to Jellyfin like I did, you’re probably already enjoying the freedom and transparency that Jellyfin provides. One of Jellyfin’s biggest advantages is free hardware transcoding, which does not require a Plex Pass.

In this guide, I will walk you through the steps to enable hardware transcoding using an Nvidia graphics card on your Unraid server running a Jellyfin container. This setup will help reduce the load on your CPU and instead utilize your GPU, which is better optimized for video transcoding tasks.

Why Use Hardware Transcoding

Transcoding allows your server to convert media formats or resolutions in real time. This is particularly useful when streaming content to devices or browsers that don’t support the format your content is in. Without hardware acceleration, the CPU must handle this process, which can significantly impact system performance, especially during multiple simultaneous streams. Enabling Nvidia NVENC allows your GPU to handle these tasks, which is more efficient and frees up your CPU for other workloads.

Prerequisites

Before enabling hardware transcoding in Jellyfin, make sure your environment meets the following requirements:

  • An Nvidia graphics card is installed in your Unraid server.
  • The Nvidia-Driver plugin is installed and configured from the Unraid Community Applications (‘Apps’ tab).
  • In the Unraid Settings tab under Nvidia Driver, the GPU is correctly recognized.
  • Jellyfin is installed and configured as a Docker container in Unraid.

Enabling GPU Access in the Jellyfin Container

  1. Open the Unraid web UI and go to the Docker tab
  2. Click on your Jellyfin container and select Edit
  3. At the top-right of the container settings page, click the “Basic View” toggle to switch to Advanced View
  4. Locate the Extra Parameters field and add the following:
    -e NVIDIA_DRIVER_CAPABILITIES=all -e NVIDIA_VISIBLE_DEVICES=all --gpus all

    These options do the following:

    • NVIDIA_DRIVER_CAPABILITIES=all enables full access to the driver’s available features such as decoding, encoding, and compute
    • NVIDIA_VISIBLE_DEVICES=all exposes all available Nvidia GPUs to the container
    • --gpus all is a Docker runtime flag that passes all detected GPUs into the container
  5. Scroll down and click Apply to restart the container with the updated configuration

Configuring Jellyfin for Hardware Transcoding

Once the container is restarted with GPU access, proceed with the following steps in Jellyfin:

  1. Log in to the Jellyfin web interface.
  2. Navigate to Dashboard, then select Playback and Transcoding.
  3. In the Hardware Acceleration section, choose Nvidia NVENC.
  4. Enable the following options:
    • Enable hardware encoding
    • Enable tone mapping
  5. Scroll down and click Save to apply the changes.

Jellyfin is now set up to use Nvidia hardware acceleration for transcoding.

Verifying That Transcoding is Active

To confirm that hardware transcoding is functioning, play a media file that requires transcoding, such as one of the formats that you have checked in the transcoding settings. In the Jellyfin dashboard under Activity, look for indicators that NVENC is being used during playback.

You can also verify GPU usage directly from the Unraid terminal by running:

nvidia-smi

This command displays real-time GPU usage and will show active encoding processes when transcoding is occurring.

Wrap Up

Jellyfin’s open approach and cost-free hardware transcoding make it an excellent alternative to Plex for media server hosts who want more control. By enabling Nvidia NVENC on your Unraid server, you can offload transcoding workloads from your CPU and improve streaming performance across your network.

Conversation

Join the conversation

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