Archiving Discord Servers

Discord is a great platform. If for some reason you have not had the opportunity to interact with it, I would suggest checking it out. Discord allows for free, instant voice and text chat with a large amount of people at once. Each “server” is usually dedicated to one topic or run by one organization and contains multiple “channels” for different subtopics. The whole thing is wrapped together in a clean interface where you can choose between different servers or even private messages to individual other users.

With all that being said, Discord also has its drawbacks. Servers are by default private and not accessible to the public internet, so important messages (bug fixes, links, etc.) are not always visible to wider audiences. This, coupled with the fact that many websites are dropping dedicated forums in favor of Discord servers, gates off information behind these unnecessary and artificial walls. An additional thread lies in irresponsible moderators who have the ability to delete messages at will. The largest concern is the one that brought me to archive these “servers”: there is no guarantee that Discord will keep them up in perpetuity once they become inactive.

I am thankfully not the only person to have this concern. There is an opensource tool on Github that does exactly what I would have had to write a script for: download every single message in a server and retain the organizational structure. DiscordChatExporter is regularly maintained and considered the go-to utility to download from Discord.

Getting it to start is relatively easy. There is a zip folder available for download on Github that contains all the necessary files. After downloading and unzipping, run the packaged executable. Windows will give you a scary warning screen about running unsigned programs, but because the executable is opensource software this is not really a concern. Click “More info”, then a button at the bottom will appear stating “Run anyway”.

The program then starts and a window pops up asking for an API token. I have had to use API tokens in the past, and gist is that they are a substitute for login credentials. While this tool requires a token in order to view your joined servers, if a malicious actor were to get this token they could steal your account. This is why you should be careful giving this information away. The description below should work for Chromium-based browsers but for the Firefox instructions (also with pictures) can be found here.

Once you enter your API token you should see the following screen. The servers you have joined are on the left, and you can click on them to show the channel groupings. Clicking on the groupings shows individual channels. From there you can download them by selecting one or, while holding the CTRL key, selecting multiple and then the yellow button.

Doing so will bring up a download menu. There are several different options to choose from, including the output format and whether to download attachments. After a few attempts I opted to save JSON data because for some reason there is much more data fetched this way than using a CSV or HTML. I also decided to download attached images such that I would not have any broken Discord links, but this added a considerable amount of download time and hard drive space.

The amount of time it takes to download an entire server’s worth of content can be up to a few hours depending on how much there is. Downloading attachments makes it take several times longer than it would otherwise. To give you a general idea, FinalBastion’s Discord server took a little over two hours to download 200 MB of text-chat JSON files and 18.5 GB worth of attachments (22,676 images). I could probably find a way to reduce this size significantly by de-duplicating the images and then zipping the whole thing together, but that is a problem for future me to solve.

Leave a Comment

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