- Find the world on your PC. Singleplayer saves: Windows
%appdata%\.minecraft\saves\<WorldName>, macOS~/Library/Application Support/minecraft/saves/, Linux~/.minecraft/saves/. The folder containslevel.datand aregion/folder. - Zip the folder so that the zip contains
level.datdirectly (notWorldName/level.dat). - Stop the server. In Files, rename the existing
worldfolder toworld-old(delete it later). - Upload the zip to the server root, right-click → Unarchive. Rename the result to
world, or setlevel-nameinserver.propertiesto your folder's name. - Paper only: a singleplayer world keeps Nether and End inside
world/DIM-1andworld/DIM1. Paper expectsworld_nether/andworld_the_end/. Start once; Paper converts them automatically and tells you in the console. - Start the server. Your spawn, builds and player data are there.
From another server
Same steps; the world folder is already server-shaped. If it came from a Forge/Fabric server with mods, install the same mods first or the modded blocks turn into air.
Version
A world can always move to a newer Minecraft version, never to an older one. Match or exceed the version it was last played on.