This article is NOT just about 1.13+. Read the whole article, please.
Do you use 1.13 / 1.14 or 1.15?
Since 1.13 Minecraft has a completely new world format to enable the new water changes. Unfortunately, this new world format isn't really optimized yet and causes lots of performance problems.
We recommend to always use the latest version, it contains the latest optimizations and fixes.
The basic performance problem is still present in the newer versions, but will hopefully improve with the newer versions.
Since 1.14.4 Mojang recommends to create a debug report and send it to them when you have performance problems so that they can find and fix the causes. You can create a debug report with the command:
You can execute that command either in-game or in the console. After that, you can find and download the report here: https://exaroton.com/files/debug Please note, that the download is only possible while your server is offline.
You can find the Mojang bug tracker to report performance problems or other bugs here: https://bugs.mojang.com/projects/MC/issues
PaperMC is a software which contains several enhancements over the vanilla version to improve performance. Additionally, it supports the installation of plugins.
You can install it here: https://exaroton.com/software/papermc/
Admittedly, PaperMC does not solve all problems and the performance is still not outstanding but still worth the switch. By the way, the rule that the newer the version the better also applies here. They always contain the latest improvements and corrections.
Also during the game, there are a few tricks on how you can reduce lags.
Mobs: For example, mobs have a big impact on performance. We do not recommend keeping many mobs (animals or monsters). Limit yourself to a few.
Items: Having many items on the ground can cause performance problems. This can for example happen when you give a player a very large number of items through the /give command. You can delete all dropped items on the ground with the command
Random tick speed: The random tick speed is a gamerule that changes how often certain random events in a world occur (read more here). Setting this gamerule to a high number can harm the performance. You can set it back to the default value of 3 using the command
/minecraft:gamerule randomTickSpeed 3
Also, loading chunks has a big impact on performance.
Exploring: Exploring new areas causes large lag spikes and decreases performance massively
Loaded chunks: It is also worth reducing the number of chunks loaded, especially if you play with several players on one server. This means that if there are many players close to each other it is better for performance than if there are many players far away from each other. We already reduced the number of loaded chunks for 1.14 and newer servers, you can find more information about that here.
Do you use plugins, mods, or a modpack?
Too many or misused mods, plugins, or worlds can cause server lags. Make sure to install a reasonable amount of plugins and don't create too many worlds. Mod features, e.g. machines or chunk loaders also can cause lags. To identify the problem here, it could be helpful to check your log (https://exaroton.com/log).
It is also possible that a single mod contains a bug or is just not really performant and causes on its own to slow down your server. Try to remove mod by mod to find out if you are affected by such.
Is your internet stable?
If your internet connection is bad or temporarily overloaded, lags may occur. To test this, you could try playing on other servers and check if there are any lags.
It is not really likely, but possible, that an exaroton host machine is temporarily overloaded. This should be only for a few minutes and only occur rarely. In this case, you can only wait or completely stop and start (not restart) your server.