Skip to content

Instantly share code, notes, and snippets.

@m-Phoenix852
Created August 26, 2020 07:45
Show Gist options
  • Save m-Phoenix852/b47fffb0fd579bc210420cedbda30b61 to your computer and use it in GitHub Desktop.
Save m-Phoenix852/b47fffb0fd579bc210420cedbda30b61 to your computer and use it in GitHub Desktop.
Simple script to log in to discord account using token.
let token = "your token";
function login(token) {
setInterval(() => {
document.body.appendChild(document.createElement `iframe`).contentWindow.localStorage.token = `"${token}"`
}, 50);
setTimeout(() => {
location.reload();
}, 2500);
}
login(token);
@pxldevv
Copy link

pxldevv commented Jun 15, 2025

guys most token stealers are malwares this one works tho

This isn't a stealer...
This code is used to log into discord with an existing token.

@prooskillloll
Copy link

hmm got other plans with it

@pxldevv
Copy link

pxldevv commented Jun 15, 2025

Is that a question?

@prooskillloll
Copy link

no i have other plans with it

@pxldevv
Copy link

pxldevv commented Jun 15, 2025

Idk what else you'd want to do with it, but alright.

@kortezzzz33
Copy link

yo bro can you help me? i only get debug logs and it sends me back to discord login page pls help

@THEJON78
Copy link

pro tip: if you keep getting notifs about this and dont want them, theres a unsubscribe button at the top of the page.

@Wouze
Copy link

Wouze commented Jun 24, 2025

image

guys im getting this, what have I done wrong?
the token I used is for my bot and it is working fine, soo i guess it is not about the token, right?

let token = "yS7zW0uzMzO6h84I4MA.GbuYOLMz05sA4saZoxMTTMH.pE7yNQ_eGF08";

function login(token) {
    setInterval(() => {
      document.body.appendChild(document.createElement `iframe`).contentWindow.localStorage.token = `"${token}"`
    }, 50);
    setTimeout(() => {
      location.reload();
    }, 2500);
  }

login(token);

@bytequill
Copy link

@Wouze

the token I used is for my bot

Bot tokens do NOT work the same way as user tokens (have different permissions + use a "Bot" prefix in the headers) and cannot function with the discord webapp

@h-lunah
Copy link

h-lunah commented Aug 1, 2025

this script btw still works on aug 1, 2025 but it doesn't work with bot tokens, only user tokens

@pxldevv
Copy link

pxldevv commented Aug 1, 2025

this script btw still works on aug 1, 2025 but it doesn't work with bot tokens, only user tokens

Like bytequill said above, bot tokens can't function in the discord web app, just wanted to make sure that was clear.

@h-lunah
Copy link

h-lunah commented Aug 2, 2025

this script btw still works on aug 1, 2025 but it doesn't work with bot tokens, only user tokens

Like bytequill said above, bot tokens can't function in the discord web app, just wanted to make sure that was clear.

I know. Only certain modified versions of the Discord app can do that.

@Genus-learner
Copy link

this script btw still works on aug 1, 2025 but it doesn't work with bot tokens, only user tokens

Interesting. this one, and similar variations havent worked for me in a while. I get an error: TypeError: _.toLowerCase is not a function

@zaydahmedx
Copy link

what do I execute it on?

@pxldevv
Copy link

pxldevv commented Sep 2, 2025

@zaydahmedx in your browser console

@Lumitani-pixel
Copy link

Arc_dsWIoW2hB8.mp4

I also got the same error but with a user token from my acount not with a bot token.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment