How to occur Client initiated disconnect (through script)

So basically, I wanna make a server shutdown script, but I want to make it look like that Roblox has shut it down.

Why would you want to make it look like ROBLOX has shut it down?

So like for example, Imagine there is a server and people don’t want to get it shutdown, when they lose their large progress, they will release that someone has shut down the server , and they could quit the game forever, So maybe If it would be Roblox shut the server down, It might prevent players quiting the game.

There’s a reason why developer kicks are required to have the prefixed “You have been kicked” and suffixed “Error Code 267” and it’s specifically so developers can’t spoof their kick messages to look like official internal disconnection messages.

Changing the kick message doesn’t guarantee your same worry of losing player retention won’t exist – the whole issue is interrupting gameplay regardless of whether it’s done by Roblox or you. Your main focus should be how to save player data properly and, if desired, transition players smoothly to servers running a new version of your experience (“soft shutdown”).

Improve your data management architecture, don’t try shifting the blame for a server closure to an uninvolved entity and hope that doesn’t dent your player retention.