This is the talk page for discussing improvements to the DiscordIntegrator page.


Can someone please simplify how to add this? It's very confusing, especially with where you should put each piece of code and what you should put in. (dev:DiscordIntegrator/code.js vs the importArticles thing). --Squirrel719 (talk) 09:00, August 3, 2016 (UTC)

You can either import the script through the importArticles function in Common.js (which will require the edit to be "verified"), or you can just add an import into the ImportJS page and bypass verification.
After that, you can either copy the template, or simply use the configuration option (which would require editing common.js and having the edit "verified"). Sajuuk 10:26, August 3, 2016 (UTC)

Load order

The script does not load the sidebar module in a consistent place - if the sidebar loads slightly slower than normal then it will be the first module in the sidebar rather than the last. Is it possible to fix this to be consistent? cqm 08:20, 18 Nov 2016 (UTC)

Yes, that is possible. -452 13:22, November 24, 2016 (UTC)
Could someone more knowledgeable something then? Since the issue persists.
~Ursuul 07:39, February 8, 2017 (UTC)
I updated it a few weeks ago, it should load below ads and content review module and above all other Rail contents. -- Cube-shaped garbage can 07:41, February 8, 2017 (UTC)

────────────────────────────────────────────────────────────────────────────────────────────────────It seems not to have worked On this Wiki & others.
~Ursuul 08:28, February 8, 2017 (UTC)

That's exactly what's supposed to happen. -- Cube-shaped garbage can 08:30, February 8, 2017 (UTC)
Oh, my bad. Is there an older version that makes it always load below all rail contents? It’s a rather low-priority module for me, especially when AddRailModule is used alongside it.
~Ursuul 08:35, February 8, 2017 (UTC)
Try using
$(function() {
    mw.hook('DiscordIntegrator.added').add(function($el) {
-- Cube-shaped garbage can 08:43, February 8, 2017 (UTC)

────────────────────────────────────────────────────────────────────────────────────────────────────Perfect! Thanks so much!
~Ursuul 08:58, February 8, 2017 (UTC)

For those of us just tuning in, where exactly should the above code be added in order to load the Discord Integrator at the bottom of the sidebar? Thanks - Pegship (talk) 16:12, May 3, 2020 (UTC)

It should be added to the MediaWiki:Common.js page on your wiki and submitted for review. -- Cube-shaped garbage can 16:23, May 3, 2020 (UTC)

Issues that it causes for two other scripts

I imported the script through ImportJS but soon removed it because I discovered that it caused problems for two other JavaScripts that I use - Talk Button and Quick Image License (the latter doesn't have it's own page). It caused those two scripts to display twice instead of once each. ― C.Syde (talk | contribs) 10:45, December 8, 2016 (UTC)

LoggedIn parameter issue

So a few days ago, the Discord widget on our wiki's front page started displaying the unregistered user message even if you're logged in; looking at the revision history of the script, I assumed this was something to do with the most recent edits and simply waited for the latest revision to get passed, though it appears as though I assumed wrong. I can't tell if this is an isolated incident or an actual bug with the script, so a response would be appreciated in order to clear that up.

~PlasmoidThunder 14:35, January 27, 2017 (UTC)

That was a bug which I fixed, it got approved about two or three days ago. The widget is displaying normally for me on that front page, can you try clearing your cache? -- Cube-shaped garbage can 15:01, January 27, 2017 (UTC)
Tried clearing the cache and cookies, null editing the page, and restarting the browser, but I still get that message.
~PlasmoidThunder 15:16, January 27, 2017 (UTC)
Awkward, I can't reproduce the issue. Is somebody else facing that issue too? Which browser/OS are you using? -- Cube-shaped garbage can 15:27, January 27, 2017 (UTC)
A few people in the wiki's chat are seeing the same issue. I'm using Google Chrome, though I can't vouch for everyone else.
~PlasmoidThunder 19:56, January 27, 2017 (UTC)
Hey there, I had the same issue as well on We Bare Bears wiki with G.Chrome last week but things seems to be fixed after I remove the script import from MediaWiki:ImportJS and then re-adding the script again, you can try that and hopefully that helps, cheers. 𝒮𝓉𝒶𝓇𝓂𝒶𝓃 𝒲 13:40, January 28, 2017 (UTC)
We have it in our Common.js, but I'll give that a try and see if anything happens.
~PlasmoidThunder 15:12, January 28, 2017 (UTC)
That seemed to do the trick, thanks.
~PlasmoidThunder 21:56, January 30, 2017 (UTC)

The script doesn't work

I tried to install this script on this wiki, I set up server settings, but the script doesn't work. --Шпик (обс.) 16:00, March 9, 2017 (UTC)

Your Common.js is throwing an error on the mw.toolbar.addButton part. Try wrapping that part of your code like
$(function() {
    mw.toolbar.addButton("", "Перенаправление", "#REDIRECT [[","]]", "");
    mw.toolbar.addButton("", "Категория", "[[Категория:","]]", "");
    mw.toolbar.addButton("", "Кавычки", "«", "»", "");
    mw.toolbar.addButton("", "Тире", "—", "", "");
    mw.toolbar.addButton("", "Ударение", "́","", "");
    mw.toolbar.addButton("", "Шаблон", "{{","}}", "");
    mw.toolbar.addButton("", "Комментарий", "<!-- "," -->", "");
    mw.toolbar.addButton("", "Развёрнутая цитата", "<blockquote>\n","\n</blockquote>", "");
    mw.toolbar.addButton('', 'Вставить таблицу', '{| class="wikitable"\n|', '\n|}', '-\n! заголовок 1\n! заголовок 2\n! заголовок 3\n|-\n| строка 1, ячейка 1\n| строка 1, ячейка 2\n| строка 1, ячейка 3\n|-\n| строка 2, ячейка 1\n| строка 2, ячейка 2\n| строка 2, ячейка 3');
    mw.toolbar.addButton("", "Примечание", "<ref>","</ref>", "");
-- Cube-shaped garbage can 16:17, March 9, 2017 (UTC)

Making the Module Appear for Users Not Logged In

Is there any way to make the module appear for users not logged into Fandom? It used to appear regardless iirc and it was helpful for drawing in new people who were on the fence about starting to edit. Roranoa Drake II (talk)

It's because it's attempting to load mediawiki.api module which doesn't load for anons. I'm aware of the bug, I just didn't get the time to fix this issue yet. It used to appear for anons back when it didn't need to query the API and took the values from JavaScript configuration. -- Cube-shaped garbage can 20:09, April 7, 2017 (UTC)
I forgot to note, this is fixed in the latest update. -- Cube-shaped garbage can 21:54, June 21, 2017 (UTC)

Empty Space Below Widget

What's up with the empty space below the widget? Is this something that can't be customized? DEmersonJMFM 20:20, April 8, 2017 (UTC)

I noticed that as well. You can customize the module's height, though, so configuring it to a correct amount should fix it. -- Cube-shaped garbage can 20:22, April 8, 2017 (UTC)
Tried that. It just reduces the space proportionally to the size of the module. DEmersonJMFM 20:31, April 8, 2017 (UTC)
Oh. Can you try using
.DiscordIntegratorModule.module iframe {
    height: 100%;
in your wiki's CSS? -- Cube-shaped garbage can 20:35, April 8, 2017 (UTC)
Worked great (I used 98%). Would like to style the text next to Connect (to be readable), but unfortunately it's in the iframe. DEmersonJMFM 20:57, April 8, 2017 (UTC)

Show Nicknames

I've used Discord for a while for gaming, but just added it to my Wikia site. A neat feature that Discord has is Nicknames, where you can change your display name dependent on the server. I've changed my Nickname for the server relating to my Wikia page to match my Wikia username, but the Widget on my page still displays my original Discord username.

I googled about and saw that some coders who'd created their own Discord widgets were able to add a showNickname boolean parameter - is that something that can be done here, or does it have to be handled over at Discord themselves?

Haldarn (talk) 10:58, May 6, 2017 (UTC)

Removing Border?

I want to remove the "box" on my wiki to fit in with the rest of the interface, but i dont know how.

I imported it before the new wiki siderail design was introduced. Searingjet (talk) 15:05, May 9, 2017 (UTC)

There shouldn't be a border on the DiscordIntegrator module, I updated it to the new design a few weeks ago. Which wiki are you referring to? -- Cube-shaped garbage can 15:14, May 9, 2017 (UTC)

Moving module under other ones

I need to move DiscordIntegrator module under other modules. Can you add a option (default "false") or sead a code which can do that? Pirr (talk) 21:49, June 21, 2017 (UTC)

I'm pretty sure you can use the code I provided in #Load order section, but modifying it to append it below a module instead of below the whole rail. -- Cube-shaped garbage can 21:53, June 21, 2017 (UTC)

Double widget

Hey, we've got two widgets on our siderail at the Elder Scrolls Sandbox, instead of just one. All we did was import the code from here and changed the server ID to the appropriate one. Does anyone know what could have caused this?
{{SUBST:User:ReDquinox/Sig2}} 21:58, July 16, 2017 (UTC)

You imported DiscordIntegrator twice. Remove the import from your MediaWiki:Common.js page. -- Cube-shaped garbage can 22:22, July 16, 2017 (UTC)

Disabling script.

Is there any chance you could add something like

if (window.DiscordIntegratorDisabled) {
    return 0; 

to allow users to add to their personal js files do disable this script? My community is using it side wide, but I really don't want to see it. -- Original Authority (talk)' (talk)' (talk)​ 13:40, August 14, 2017 (UTC)

For now this works:</dd>
mw.loader.using('mediawiki.util').then(function() {
    mw.hook('DiscordIntegrator.added').add(function($el) {
But if the script had double run protection, that variable could be set as true instead. speedy🔔︎🚀︎ 13:56, August 14, 2017 (UTC)
EDIT: Maybe use .DiscordIntegratorModule { display: none; } too. :p
Thanks, that worked. Yeah, definitely. Double-run protection should be a feature already for a script of this purpose. — Original Authority (talk)' (talk)' (talk)​ 20:00, August 14, 2017 (UTC)
In the next update you should be able to use window.DiscordIntegratorLoaded = true; to prevent the iframe from loading completely. This, however, will also disable the in-content widgets for you. -- Cube-shaped garbage can 11:58, August 27, 2017 (UTC)

Preview Shows Error

So I drove myself nuts to finally realise I had done everything correctly, but when you preview a page that has the template on it, it will give you the "If you see this, your JavaScript might be disabled or DiscordIntegrator plugin isn't working. If the latter, please contact a wiki administrator." error. It isn't until you publish that the widget will show- this happened on both my wiki and trying it out on the dev wiki. Is this already written in somewhere that I missed? Is it even supposed to do this? Bluesonic1 (talk) 05:14, October 29, 2017 (UTC)

That, while perhaps not intended, is normal; JS doesn’t usually fire in Preview. You will have to save the page each time you rely on JavaScript in order to see how it will look.
UrsuulTalkCMDate5:17 AM Sunday, October 29, 2017 (UTC)
I modified the script now so it should work in preview after it gets approved. -- Cube-shaped garbage can 07:18, October 29, 2017 (UTC)

Rail Compatibility

I was given the following script to ensure that the Discord Module stays at the bottom of the rail:

$(function() {
    mw.hook("DiscordIntegrator.added").add(function($el) {
However, it causes this to happen:

Is there a way to stop that overlap from occurring, a way to make the Module always be directly above the TFA Module / Advertisement? This issue also occurs with AddRailModule, & a fix for that would be greatly appreciated.
UrsuulTalkCMDate7:46 PM Tuesday, November 21, 2017 (UTC)
I have a personal use method for that. It is called Anti-TFAFloat, which makes that TFA module stop from floating. ~Signed JustLeafy ( ͡| ͜' ͡| ) USER WALL 20:31, November 21, 2017 (UTC)

Remove/Hide channel name?

How do I remove/hide channel name on widget?

MakBash (talk) 08:44, November 27, 2017 (UTC)

Would be interested in this as well. We got several voice channels on the discord server, so that the actual list of people online starts at about the lower half of the widget. HolyCrap WOTF (talk) 20:19, January 7, 2018 (UTC)

Try moving your voice channels to a channel category, they don't appear for me on Undertale Wiki. -- Cube-shaped garbage can 20:22, January 7, 2018 (UTC)
Those channels are already in a category. Tried moving them to another category; still showing up. Is there any other setting I have to change? HolyCrap WOTF (talk) 20:42, January 7, 2018 (UTC)


We are currently trying to include our discord server to this wikia, and everything works fine, until I wanted to add the server to my sandbox to try it out and to the sidebar, where it suddenly doesn't work.

~ Lava 20:11, December 28, 2017 (UTC)

JavaScript is not enabled on that wiki. Use Special:Contact/general to ask Staff to enable it. -- Cube-shaped garbage can 20:33, December 28, 2017 (UTC)

Grouping users by role

Is it possible to group users displayed by role. So, for example start with the admins at the top, then moderators, then "normal" users? HolyCrap WOTF (talk) 20:21, January 7, 2018 (UTC)

Infinite Loop

Hello, my wiki's discord integrator is stuck on an infinite loop, despite having done the instructions in order, followed to a tee. It looks perfectly fine on the template itself, however, when placed on the sidebar, is stuck in infinite loading. If you can help, please let me know.

User talk:Astrarche

{{SUBST:Astrarche/Sig}} 02:28, February 1, 2018 (UTC)

That usually means you haven't enabled the widget. Did you? -- Cube-shaped garbage can 05:54, February 1, 2018 (UTC)

2 Widgets

I need to add 2 Discord widgets on the sidebar. Is that possible and if yes, how?Lica-Citrin (talk) 02:05, March 16, 2018 (UTC)

It's most likely possible by using a Discord widget inside an AddRailModule module. -- Cube-shaped garbage can 22:36, March 28, 2018 (UTC)

Only works on Custom-DiscordIntegrator-config-id

Hello, I tried using the widget on This wiki, but the only place it actually shows up is in This page.

Thanks in advance—Preceding unsigned comment added by Succmeister (talkcontribs) . Please sign your posts with ~~~~!

It works in every page's sidebar for me. -- Cube-shaped garbage can 17:30, March 26, 2018 (UTC)

Widget banner customisation

A suggestion for the summer :)

Perhaps a MediaWiki:Custom-DiscordIntegrator-config-style option, to generate a linked banner image (instead of iframe)? speedy🔔︎🚀︎ 00:53, April 14, 2018 (UTC)

Sidebar Issues

I did all the steps, they all work, but for some reason, on the main page of my wikia, the discord does not go to the sidebar. what should I do? CNBA3 (talk) 13:38, July 26, 2018 (UTC)

Try move {{DiscordIntegrator}} template transclusion under <mainpage-rightcolumn-start /> tag. – Pedyjczyk    13:45, July 26, 2018 (UTC)

Link missing

Over at the Realm-Mesh Reality Wiki's main page, the link to join the associated Discord channel is oddly missing. I'm pretty sure that I did everything right, but clearly I did something wrong...Could someone help with this? Thanks in advance if someone helps! Wikikinetic (talk) 19:22, August 13, 2018 (UTC)

It looks like you didn't set the "Instant Invite Channel" setting in Server Settings > Widget. -- Cube-shaped garbage can 19:23, August 13, 2018 (UTC)
Thanks for pointing that out! The link works now, thanks to you. :) Wikikinetic (talk) 20:24, August 13, 2018 (UTC)

Discord widget appearing squished in sidebar

Discord widget appearing very short in the sidebar

The widget in the sidebar appears like this.

On The Sims Wiki and The Last Stand Wiki, the Discord widget in the sidebar appears very short and squished, leaving barely any room for the user list to show. I've been able to reproduce this issue in Google Chrome and Mozilla Firefox despite clearing cache and using incognito mode. This issue has been going on for months now, but I've been unable to figure out the cause. —k6ka 🍁 (Talk · Contributions) 17:56, October 22, 2018 (UTC)

Here's a solution: create MediaWiki:Custom-DiscordIntegrator-config-moduleHeight with nothing but 500 in it, no "px" or "%" suffix. Seems to have restored the module to normal height. From [1]. —k6ka 🍁 (Talk · Contributions) 19:12, October 22, 2018 (UTC)

Widget Position

Is there a way I can force the widget to load on top of all other contents in the siderail? Above Let's Chat, Recent Activity, and all that? RickGT 21:21, November 11, 2018 (UTC)

It should already be above all those except the content review module. Where are you not seeing it above these modules? -- Cube-shaped garbage can 21:22, November 11, 2018 (UTC)
On all pages as the template was added to our RailModule
RickGT 23:56, November 11, 2018 (UTC)
So you're not using DiscordIntegrator at all, you're using AddRailModule.
To make AddRailModule prepend the module, add window.ARMPrepend = true; into your Common.js.
-- Cube-shaped garbage can 00:01, November 12, 2018 (UTC)

Can't import

I can't import the DiscordIntregator script to the MediaWikiJS because it says it was protected to prevent abuse. Could someone give me help? --Pradiptamf (Want to leave a message?) 00:43, March 2, 2019 (UTC)

VSTF has wrong abuse log report.--*Lac*() 11:30, March 4, 2019 (UTC)

Am I doing this right?

I already did what the page told me to do here and here. But I'm not sure if I'm doing it right. I think I'm stuck. Did I do something wrong? Master of Memes 23:06, March 15, 2019 (UTC)

Never mind, I got it. It works! Master of Memes 23:08, March 15, 2019 (UTC)

Help with discord

I am trying to integrate discord into my Wiki, the Darth jar jar Wiki, (, and the discordintegrator wants me to paste the following text:

" data-logged-in="{{{loggedIn}}}" data-usePTB="" data-theme="dark" data-width="300px" data-height="500px" data-allowtransparency="true" frameborder="0">If you see this, your JavaScript might be disabled or DiscordIntegrator plugin isn't working. If the latter, please contact a wiki administrator.​</span>

But I don't know where to paste the text. Can someone help me? ARZ100 (talk) 13:09, May 10, 2019 (UTC)

DiscordIntegrator Sidebar

Hello, I was wondering how to place the DiscordIntegrator widget below the chatroom box widget on the sidebar of my wiki?

Thank you!

FullerHouseFan01 01:28, August 24, 2019 (UTC)


The Discord widget is not appearing on the front page of my wiki, I've done all the right steps. Taz.davos (talk) 10:20, November 15, 2019 (UTC)

Please always link to the page where you're having issues when requesting help. -- Cube-shaped garbage can 22:42, November 25, 2019 (UTC)
Community content is available under CC-BY-SA unless otherwise noted.

Fandom may earn an affiliate commission on sales made from links on this page.

Stream the best stories.

Fandom may earn an affiliate commission on sales made from links on this page.

Get Disney+