Ade Malsasa Akbar contact
Senior author, Open Source enthusiast.
Sunday, October 29, 2023 at 14:21

This simple tutorial will help you join separate MKV video files into one my using mkvtoolnix command from the MKVToolNix software package. We use this in real life for merging separate sessions of our online course recordings and it is fast. However, this tutorial only discuss the merging and for converting into another format we recommend you to use FFmpeg. Now let's do it!

Subscribe to UbuntuBuzz Telegram Channel to get article updates.



You are required to do the following command line:

$ sudo apt-get install mkvtoolnix

This command will install mkvtoolnix software package into your Ubuntu computer. This package contains three command lines namely mkvmerge, mkvinfo and mkvextract. This tutorial will use the first one.


If we have





then we want to join them to a single MKV file



then we should do the methods below. 



Do this command line:

$ mkvmerge video-01.mkv + video-02.mkv + video-03.mkv -o video-final.mkv



$ or dollar sign means the command is executed as normal user (not admin).

mkvmerge means the command to do the job of merging separate videos.

video-{01,02,03}.mkv means the first, second, and third video file names.

+ means sign to join the first to the second to the third video in order.

-o means sign to create the output as a single video.

video-final.mkv means the output video file name.


Wait for the process until output message says "Progress 100%".



Pay attention to picture below.


To the left, there are three source video files. 

To the right, there's the command line and the processing output.

To the left again, there's the final output video file.

You can see the out message says "Progress 100%" as the sign of finished processing.

Now play the video with VLC Media Player or any player you have.




See Also

In case you want to convert MKV to MP4:

How To Convert MKV to MP4 with Good Quality, Reduced Size






This article is licensed under CC BY-SA 3.0.