Resources/Server, for example Resources/Server/MyPlugin/main.lua. It reacts to server events: you write a function and connect it with MP.RegisterEvent("onPlayerJoining", "myFunction"). Some events, such as onChatMessage and onVehicleSpawn, can be cancelled by returning 1. Your FREAKHOSTING server runs Lua 5.3.5.
How to create a BeamMP Lua plugin
1
Create the folder
In the Game Panel, open Files, go to
Resources/Server and create a folder, for example Welcome.2
Create the script
Create
main.lua in that folder and paste the example below.3
Restart
Restart the server.
print() output and Lua errors appear in the console with a [LUA] prefix.Example: welcome message and timed announcement
Which events can a BeamMP plugin use?
Which MP functions are most useful?
The full list is in the official BeamMP server scripting reference.
Do I need to restart after editing a plugin?
Saving a file directly in a plugin’s folder reloads that plugin. Files in subfolders don’t trigger a reload, and files or folders added while the server runs aren’t watched, so restart after adding a new plugin.Frequently asked questions
Can I use several Lua files in one plugin?
Yes. Every.lua file in the plugin folder loads in alphabetical order. Files in subfolders only load when you require() them.
Where do I see my plugin’s errors?
In the panel console and inServer.log.
Can a plugin change server settings?
MP.Set changes some settings for the running server only. The panel writes the Startup values back at the next start. For more player slots, open a ticket.
Related guides
BeamMP server guide
Every BeamMP page in one place.
Add chat commands
/help and /players example.
Restrict vehicles
Vehicle allowlist plugin.
Anti-grief protection
Ban list plugin.
Console commands
The Lua console and more.
Checked against the official BeamMP server scripting reference on 3 November 2026, with file paths from our Game Panel (BeamMP Server v3.9.3, Lua 5.3.5).
Need Extra Help?
If you encounter any issues, our support team is ready to assist:- Live Chat: Quick assistance via our website.
- Support Ticket: Open a Ticket
- Discord: Join our Community
- Email: support@freakhosting.com
Last Updated: November 2026