Convert DEM to MP4

The Source engine DEM game replay format export to MP4 video. Exporting demos into MP4.

How to convert dem to mp4 file

What is dem to mp4 conversion?

Several completely different .dem file types exist, but when it comes to dem to mp4 conversion, users who are interested in exporting .dem game replays to MP4 video mostly search for it.

What are the dem replay files?

DEM replays are mainly known for their replays from DOTA 2 or Team Fortress 2 games, based on the Source 2 engine. The DEM format is used for the default replay function across all games based on the Source/Source 2 engine, but there are differences, and not every file is the same; only the core functionality remains the same. These files are often called 'demos', especially in older titles.

The Source engine provides a collection of tools for recording a game to dem files for editing and subsequent playing, which are available via console commands or GUI tools such as the Demo playing window, Demo Editor, and Demo Smoother. But most game titles provide their own functions and features to deal with replays, their recording, and playback.

Commands for the Source engine work universally in all games based on it, and when it comes to the demo recorder, the technical aspects and list of commands can be reviewed at the Demo Recording tools page on Valve's Developers Community website. But again, some games might use unique commands or alter existing ones.

The built-in gameplay recording mechanism in Counter-Strike: Global Offensive, for instance, uses the following three commands: record, stop, and playdemo for ingame handling of .dem files.

Is it possible to export the dem files to mp4 directly?

This is actually one of the core functions of the tools from Valve's Source engine, but it may be very complicated for users unfamiliar with video editing and making. The original function essentially creates a series of TGA image frames and a WAV audio file for the audio track, which users have to manually merge and edit using a video editor to produce their own recordings. It is the most commonly mentioned free tool, but any video editor will do this conversion.

Various titles offer their own functions; for example, Team Fortress 2, in the past, used recording directly in AVI format, but now h264 codecs are used instead. DOTA 2 has no such function beyond the core functions from the Source engine and the .dem files.

How do you convert the dem files to MP4?

No single working guide would work for every game based on the Source engine. The simplest way is to record the game replay playback using Fraps, OBS, or a similar screen recording tool. More skilled users can mix it with the default Source demo commands to create more spectacular demos.

Work with your .dem file

Download or locate the .dem file for your particular game; the replay folder is typically found in the default Steam folder of your game. For example, for DOTA 2, it is Steam\SteamApps\common\dota2\replays folder.

Also, make sure your dem file matches the game version; very old files often cannot be played back, which means you will have to revert to the previous version if possible.

Setup your screen recording tool

Choose a screen recording tool you are comfortable with or have experience with. Configure the tool and become acquainted with its features. You can change configurations like key binding and output formats.

Launch your game demo replay and record it

You can use Source engine commands to adjust a particular POV or let it run as recorded. Once you have the recording, you often have to manually edit it to cut out unwanted content and export it to a particular video format. MP4 is the default choice for many screen recorders.

Additional formats for
dem file conversion

Share on social media: