How to host your discord bot online 24/7 - FOR FREE!

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
this is how you can host your Discord bot online 24/7 for free so let's go and get started before I show you how to do this I'd like to say that if you're interested in getting the source code from all of my videos on my channel you can get a God or a super tier on YouTube or you could get a god tier on Discord you can also get any of these bot packages there is an AI bot package as well we're just fixing up some issues with that but all of this will be in the description below if you're interested and with that let's go ahead and get into the video all right so to start we're going to go ahead and go to the website in the descript descrition below this is going to be pyx nodes this is going to be the free Discord bot host we're going to be using you can go ahead and click continue with Discord or you can sign up with something else I'm just going to go ahead and continue with Discord you're going to go ahead and authorize pilx to your Discord account it's going to get access to a couple of things I do believe it's going to add you to their Discord server so just keep that in mind and you can go ahead and click on authorize and it's going to go ahead and log you in all right so you're going to be brought to your dashboard here and we're going to go ahead and basically just create a free host so so what you're going to go ahead and do is you're going to go ahead and click on create in the top and we can just go ahead and provide a bunch of details for our host so my server name is going to be tutorial host the description can be host my Discord bot just like that and then we can go ahead and select the free plan we're going to go ahead and select a server image which is going to be discord.js discord.py or Minecraft but for this tutorial is going to be discord.js because that's what this whole channel is based on so we can go ahead and select that and and it's going to go ahead and say almost done just go ahead and make sure you have all of this correct and then we can actually go ahead and click on create server right here so now that you have your server you will notice that you have a server down here and we can actually go ahead and click on manage so a couple things to note you can rename your server and description and you're also going to have to renew your server I went ahead and clicked on it and as you can see you're going to have to renew it about every 5 days so if you plan on hosting your Bot on this for a long time make sure you check in every 5 days to renew it otherwise the host will actually goe and delete your server so now that you know that you do have to renew This Server every 5 days let's go back over to our dashboard and you might get a notification here in this area that looks something like this it says servers created press here to view your panel credentials for me it didn't actually show up but if you don't have that green alert that will have a link just go ahead and click on the account section at the top I am going to have to blur some stuff out but once you're here just go ahead and click this goto panel button and and it will take you directly to the panel now keep in mind they are working on integrating this panel within their dashboard directly but as of now it is separate now keep in mind if it doesn't load right away just go ahead and click on controlr and it will load you right in here and you're just going to go ahead and log in with the account information that you had before so to do that we can actually go back to the pyx dashboard and we can go back over to account and you're going to notice there's an email and a password here obviously it's going to be blurred out but you're going to go ahead and sign in to this panel right here with that email and password that is provided within the account all right and after about 20 minutes of doing captas I finally got in so now that we're here all you have to do is just go ahead and click on your host which will be in the panel and it's going to go ahead and bring you to your console so just go ahead and give it a second and it should load all in what you're going to want to go ahead and do is we're going to go over to files and we're going to go ahead and upload all of our files basically what you're going to go ahead and do is you're going to go ahead and create a new zip on your desktop and you can just go ahead and call this whatever you want I'm just going to go ahead and do host zip for tutorial cuz I have a bunch of other host Zips and we can actually go ahead and open this up now what you're going to go ahead and do is you're going to open up your Bots code and you can just go ahead and drag all of it into this zip folder do not include the node modules or anything else you do not need but make sure you have the package Json and your package lock Json as well as your EnV and your SRC files if you're using replit or some other host try your best to download all the files into a zip folder I believe repet does allow you to actually download files some may not so this might not work for you but if you can have access to your files that would be best so once you do that we can actually go ahead and close out of both of these and we can go back into the host we're just going to go ahead and drag this over here and we can just go ahead and drag that host zip into the files so we're just going to go ahead and give it a second to load and then we can go ahead and click on these three dots and we're going to go ahead and click on unarchive once we do that all we have to do is delete that host zip from from the files and now we have all of our files here so let's go ahead and go over to Startup and we're going to have to go ahead and change our JS start file to the main file that runs your Bot so for me my main file is index.js but it's within my SRC folder so I'm going to go and change that to SRC index.js now this may be different for you so just go ahead and check where your main file is and correct the actual path to it now we might need to come back in here to install additional node packages if they don't actually install on their own but other than that we should be good with everything in here there is one thing to keep in mind you are going to have to select the node.js version that you're actually on so to do that what you're going to want to go ahead and do is you're going to go over to your terminal which is the terminal that your Bot would run in so your code terminal you can do this within Visual Studio code or whatever and all you're going to go ahead and do is type node and you can go ahead and click enter it's going to say welcome to nodejs version 18.2.1 so for me my node.js version is 18 so I'm going to go ahead and switch it to the 18 version yours might be different so make sure you switch your Docker image to that version once you do that we should be good to go so let's just go over to our console and we can go ahead and click on start now this might take a couple of minutes so if it doesn't happen right away be patient you could try to reload the page but I think it would just be best to give it five maybe 10 minutes depending on how slow this actually is and then your Bot should turn on all right so as you can see in the console here we got the error could not find module discord.js if you get any of these errors where it cannot find a specific package module all you have to do is go over to the startup and we're going to go ahead and do additional node packages all you have to do is put in discord.js and as you can see for this host we're going to have to use spaces to separate so let's say you put in discord.js and it turns on then that's all you have to do but let's say you put in discord.js you refresh it and you get another package that's not installed all you have to do is do a space and then you could type in that other package name so now that we have discord.js in our additional node packages let's go ahead and go back over to the console and we can go ahead and click on start one more time we'll go ahead and give it 5 more minutes to actually work and now it should turn on unless we have any other packages that we actually need to install and as you can see here after a couple of minutes my bot did turn on and it successfully installed the discord.js package now it is important to note if it doesn't work for you after putting in that additional node package if you go over to files you can actually go ahead and delete the cache the mpm and the node modules and then you can go back over to the console and turn it on and that will refresh it and let it reinstall and then it should turn on and if we go to our Discord server here as you can see the bot is online and I'm just going to go ahead and close out of the terminal and everything else that might be running it and if we were to go ahead and run a command we can just do this as you can see it does work the bot is online now there's a couple more things I want to mention the first one is the free nodes are available in the United States so if you're out of the country you can still use this it's just your ping will be a little bit higher the other thing is this company does rely on the ads that they play on this poost so if you're using an ad blocker it would be best to turn it off so that they can still provide this free host for you to use the other thing is when you renew the server uh you should get 14 more days and then you have to renew it again it is free to renew it's just a way that pyx makes sure you're still an active user so just go ahead and renew it every time you need to renew it and you should be good to go all right so that's how you can host your Discord bot online 247 for free if you do need any help with this go ahead and join the Discord server in the description below but you can also use the pyx support channels you will be Auto added to that and you might as well just Join This Server anyways because it is a pretty good coding community and with that I will see you guys in the next video
Info
Channel: MrJAwesome
Views: 23,882
Rating: undefined out of 5
Keywords: #discord, #discord bot, #discord.js v14, #tutorial, #codeadiscordbot, #discordtutorial, #bothosting, #free, #discordbothosting, #24/7 bot hosting, #24/7 discord bot hosting, #free discord bot hosts, #best free discord bot hosts, #free discord bot hosting, keep your discord bot online, get your discord bot online 24/7
Id: GAm9SBKEySM
Channel Id: undefined
Length: 8min 23sec (503 seconds)
Published: Sat Dec 16 2023
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.