Due to legal reasons, Ubuntu does NOT include multi-media codecs out-of-the-box for audio and video playback. It’s however easy to install them via a single command.
During the Ubuntu installing process, it provides an option “Install third party software for graphics and Wi-Fi hardware and additional media formats” in the wizard. If you didn’t enable it, Ubuntu refuses to play movie and sound via the default Totem media player and Rhythmbox music player.
Without installing third-party player with bundled codecs, you can simply install the ubuntu-restricted-extras package to fix the issue. The package does not contain anything, but tells to install the following packages for you:
ttf-mscorefonts-installer
– Install Microsoft TrueType core fonts.unrar
– non-free package enables ability to extract rar package in Ubuntu.libavcodec-extra
– FFmpeg library with encoder / decoder for audio and video codecs.chromium-codecs-ffmpeg-extra
– FFmpeg codecs for Chromium based web browser.- And a few gstreamer1.0 plugins for audio / video playback, recording and editing.
How to Install Media Codecs in Ubuntu:
Firstly, open a terminal window either by searching from the ‘Activities‘ overview screen or by pressing Ctrl+Alt+T on keyboard.
When terminal opens, copy and paste the command below into it and hit Enter:
sudo apt update && sudo apt install ubuntu-restricted-extras
Type your password (no visual feedback for security reason) when it prompts and hit Enter
For Ubuntu flavors, e.g, KUbuntu, and LUbuntu, there are relevant package to install the commonly used media codecs and fonts.
For KUbuntu users, open terminal emulator from start menu and run the command below instead:
sudo apt update && sudo install kubuntu-restricted-extras
And for LUbuntu, open terminal from start menu and run the command:
sudo apt update && sudo install lubuntu-restricted-extras
That’s all. Enjoy!
wow !! its working very well………….thanks jim
Thanks, great work!!!
hi it’s not work on 17.10
Thanks man. I couldn’t do without my music and movies.
Well done Jim
When I try to sudo the restricted extras package I get an error saying it cannot locate such package.
You need to run “sudo apt-get update” before it will work.
I still dont understand,
its say “E: Unable to locate package ubuntu-restricted-extras”
what should i do, when i want try instal from Ubuntu Software Center its stuck at installing but never done
my Internet connection very fast
1. Search for and launch “Software & Updates” from app launcher. In first tab, make sure the top 4 check-boxes (main, universe, restricted, multiverse) are enabled.
2. Reload your system repositories when close “Software & Updates”, or run command:
sudo apt-get update
Try the 2 steps and it should work
please i just finish installing but it stock with the license
i can click on okay to continue
Same thing here its stock in the license agreement.
just use arrow keys to navigate focus on the OK button, then press Enter
Mee too it won’t let me click ok
You need to press TAB to activate the “OK” button. Not immediately obvious!
THANK YOU!!!
(How in the world this could ever be considered acceptable UX…?)
i’m rewrite this article on my blog
please help me
Thank you so much ! I was lost without music and movies.
Worked 100%. Thankss alot…
Hi it’s not work in ubuntu 17.10
x2
Thank you..
That worked like butter..
I want to install media files on my laptop which has Ubuntu OS. Can you explain in laymens terms how i do that please.