How to Cast Video from Ubuntu to Chromecast

Chromecast is a device that allows you to seamlessly cast content like audio, video on television over your home network. It is plugged into your Televisions’ HDMI port. You can use Chromecast to cast media from your mobile devices or from your computer to your TV. It is the best and affordable way of casting media on your television using a Chromecast device.

In this article, we will see how to cast video from Ubuntu 20.04 LTS to Chromecast.

Three ways to cast videos from Ubuntu to Chromecast

We can cast videos from Ubuntu to Chromecast devices using the following ways:

  1. With Mkchromecast on Terminal.
  2. Using VLC player.
  3. By using Google Chrome.

Before starting, make sure the Chromecast device and the source device i.e mobile or computer are on the same network.

1. Send a Video stream to Chromecast using Terminal

We can use Terminal to cast local or YouTube videos to Chromecast. For that, we have to install Mkchromecast. Mkchromecast is a program that we can use to cast media (Audio and video) from macOS X or Linux to your Chromecast device. So let’s get started with its installation.

1. First, launch the Terminal by pressing Ctrl+Alt+T and then enter the following command in order to install Mkchromecast:

$ sudo apt install mkchromecast

Install MKChromecast

Wait for a while until the installation is completed.

2. Then, we will need to pair the Chromecast device with Ubuntu. Open up the Terminal and then run the following command:

$ mkchromecast –t

It will list the available devices on the network.

List network devices

Click on the Chromecast icon in the system tray area in the desktop’s top right corner to search for a media streaming device. Select the name of the device you want to cast to. If there is no device listed, click on Search for media Streaming Devices. You can also configure various settings from here.

Select streaming media target device

3. To cast a local video from Ubuntu to your Chromecast device, open up Terminal application in Ubuntu. Then run the command by using the following syntax to cast a video:

$ mkchromecast --video -i [path/to/video]

Cast a local video from Ubuntu to your Chromecast device

Below in the Terminal, you can see the following information:

  • IP Information about the streaming media device i.e TV
  • Local IP of the Ubuntu.
  • Media type

Terminal result

We can also cast YouTube videos directly from the Terminal. For that run the command in Terminal using the following syntax:

$ mkchromecast –y [youtube-URL] --video

Cast YouTube videos directly from the Terminal

However, make note that casting the YouTube video using this way will first download the video in your system and then will cast that downloaded video on your Chromecast.

Send YouTube Video to Chromecast on Linux

To stop casting a video at any time, press Ctrl+C.

2. Using VLC player to send Video to Chromecast

We can also cast videos from Ubuntu to Chromecast using the most popular VLC player. The VLC media player has built-in Chromecast support.

1. Launch the VLC player in Ubuntu. Then play any video in VLC player that you want to cast on your streaming media device.

2. From the top menu, click on Playback.

3. Hover the mouse over the Renderer, it will show the list of available Chromecast devices.

4. Select your device. It will start casting the media on your media streaming device.

Use VLC Player to stream to Chromecast

3. Send Media to Chromecast using Google Chrome

Chrome browser is another way that allows you to cast online videos to Chromecast.

1. Launch Google Chrome in Ubuntu and open any video.

2. Click on three vertical dots on the right corner of the chrome browser to open up the menu.

3. Click on Cast to start casting the video on the Chromecast device.

Use Google Chrome to stream on Chromecast

4. Then on the top right side of the Chrome browser, you will notice Chromecast icon (1), click on it to open a pop-up window.

5. From here, you can select the Casting device (2) and the Source (3) which you want to cast. From the sources drop-down, select the Cast tab option.

Select the source

Whatever video, you have opened, will be cast to the Chromecast device. If you do not select any source, the Chromecast device will automatically start casting the opened tab by default.

To stop casting a video, close the tab or click on stop casting under the device name as shown in the below image.

Stop casting in Chrome

That is all for it. You can see that simple is it to cast any video from Ubuntu to a Chromecast device. You can cast any video to Chromecast, whether it is locally saved on your computer, YouTube video, or any other video running on your Chrome browser.

Other Applications

There is one more application that you might want to have a look at, it is called Gnomecast.