{"id":508,"date":"2026-09-29T05:56:52","date_gmt":"2026-09-28T21:56:52","guid":{"rendered":"http:\/\/www.phukienhonda.com\/blog\/?p=508"},"modified":"2026-09-29T05:56:52","modified_gmt":"2026-09-28T21:56:52","slug":"how-to-optimize-a-spigot-server-41f4-4d05e4","status":"publish","type":"post","link":"http:\/\/www.phukienhonda.com\/blog\/2026\/09\/29\/how-to-optimize-a-spigot-server-41f4-4d05e4\/","title":{"rendered":"How to optimize a Spigot server?"},"content":{"rendered":"<p>If you run a Spigot server\u2014whether it\u2019s a small community survival server, a minigame hub, or something in between\u2014you\u2019ve probably felt that familiar pain mid-session: players lagging for no obvious reason, random disconnections, or the entire server chugging when someone fires off a big TNT cannon or spawns a dozen mobs at once. I\u2019ve been there. As someone who\u2019s spent the last five years running a Spigot server supply business, I\u2019ve worked with hundreds of server owners who thought their setup was \u201cgood enough\u201d only to see player retention drop or get panned in server lists for poor performance. Today, I\u2019m pulling back the curtain on the actual, tested optimizations we share with our clients\u2014not the clickbait \u201c10 tricks\u201d you see on random YouTube guides, but the science-backed steps that keep Spigot servers running smooth, even when player counts spike. <a href=\"https:\/\/www.shunyecasting.com\/spigot\/\">Spigot<\/a><\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.shunyecasting.com\/uploads\/47565\/small\/closed-axial-flow-pump-pump-impeller09208.jpg\"><\/p>\n<p>First, let\u2019s get one thing straight: Spigot is already optimized out of the box compared to vanilla Minecraft, but it\u2019s not set-it-and-forget-it. Most owners skip the foundational stuff and jump straight to plugin swaps or custom mods, which usually makes things worse. Let\u2019s start with the core: your server\u2019s hardware and JVM setup, because you can\u2019t optimize software for bad hardware. I see so many new server owners skimp on RAM to save a few bucks, but Spigot\u2019s JVM is a hungry beast. For a 200-player survival server, we recommend at minimum 8GB of dedicated RAM, and 12GB if you\u2019re running custom world generators or a lot of entity-heavy plugins like mcMMO or Jobs. The key here is dedicated RAM\u2014don\u2019t share memory with other apps on your host machine, because even a background process using 512MB of your host\u2019s RAM can trigger garbage collection spikes that crash or lag your server.<\/p>\n<p>Next, the JVM arguments. This is where most owners go wrong, copying arguments from a 10-year-old guide that were never updated for modern Spigot versions. The JVM (Java Virtual Machine) is what runs Spigot, and tweaking its settings directly impacts performance. For modern Spigot 1.19+, here\u2019s the baseline we give all our clients: <code>-Xms8G -Xmx8G -XX:+UseG1GC -XX:+ParallelRefProcEnabled -XX:MaxGCPauseMillis=200 -XX:+UnlockExperimentalVMOptions -XX:+DisableExplicitGC -XX:+AlwaysPreTouch -XX:G1NewSizePercent=30 -XX:G1MaxNewSizePercent=40 -XX:G1HeapRegionSize=32M -XX:G1ReservePercent=20 -XX:G1HeapWastePercent=5 -XX:G1MixedGCCountTarget=4 -XX:InitiatingHeapOccupancyPercent=15 -XX:G1MixedGCLiveThresholdPercent=90 -XX:G1RSetUpdatingPauseTimePercent=5 -XX:SurvivorRatio=32 -XX:+PerfDisableSharedMem -XX:MaxTenuringThreshold=1 -Dusing.aikars.flags=true -Daikars.new.flags=true<\/code>. Wait, I know that looks like gibberish, but here\u2019s what it actually does: <code>-Xms<\/code> and <code>-Xmx<\/code> set the initial and maximum RAM to the same number (this prevents the JVM from resizing heap memory mid-session, which causes lag spikes), the G1GC garbage collector is the best modern option for Spigot, and the other flags fine-tune how the JVM manages memory so it pauses players less often during garbage collection. We test these arguments on every server we set up, and we never deviate from them unless a client has a specific edge case\u2014like a 500-player minigame server, which would need an extra <code>-XX:G1NewSizePercent=40<\/code> to handle more frequent object creation.<\/p>\n<p>Once the hardware and JVM are sorted, it\u2019s time to move to Spigot\u2019s built-in configuration settings. This is another area where default settings are terrible for performance. The <code>spigot.yml<\/code> file is your first stop. Let\u2019s break down the most impactful settings, not the ones that are just \u201cquality of life.\u201d First, <code>world-size: 10000<\/code>\u2014wait, no, wait, that\u2019s the maximum world border size, but actually the key setting here is <code>chunk-gc-period-in-ticks: 6000<\/code>. Chunk garbage collection is when Spigot unloads unused chunks from memory, and the default is every 600 ticks (1 minute), which is too frequent. We set this to 12000 ticks (20 minutes) for most servers, because unloading chunks too often can cause lag when players travel long distances. Next, <code>max-tick-time: 60<\/code>\u2014the default is 50, which is way too low. This setting is the maximum time (in milliseconds) a single tick can take before Spigot flags it as laggy. If you set it to 60, you give the server a little more breathing room for heavy ticks like mob spawning or TNT explosions, without letting it spiral into unmanageable lag. Also, turn off <code>save-user-cache-on-stop: false<\/code> in <code>spigot.yml<\/code>\u2014saving user data on server stop is unnecessary and only adds to disk I\/O time.<\/p>\n<p>Don\u2019t forget <code>bukkit.yml<\/code> either. The default settings here are optimized for single-player, not multiplayer. The most important setting is <code>settings: allow-end: false<\/code>\u2014if you don\u2019t use the End dimension at all, turning it off disables all End-related calculations, which saves a ton of resources. We also set <code>settings: view-distance: 8<\/code>\u2014wait, hold on, view distance is a balancing act, but the default of 10 is way too high for mid-sized servers. For a 100-player survival server, 8 is perfect: it reduces the number of chunks the server has to send to each player, cutting network and CPU load, and most players won\u2019t notice much of a difference if you also set <code>client-view-distance: 10<\/code> in the server\u2019s resource pack or a client-side mod like Sodium. The other key setting in <code>bukkit.yml<\/code> is <code>spawn-limits<\/code>\u2014the default spawn limits are way too high. We drop <code>monsters: 70<\/code>, <code>animals: 20<\/code>, <code>water-animals: 10<\/code>, and <code>ambient: 15<\/code> for most servers. High spawn limits mean more mobs, which mean more pathfinding calculations, more entity updates, and more lag when multiple mobs are in the same area. If you need more mobs for a custom plugin, adjust this setting in the plugin\u2019s config instead of increasing the global spawn limit.<\/p>\n<p>Now, moving to plugins\u2014this is where most server owners make their biggest mistake. I can\u2019t tell you how many clients come to us with 150 plugins on a server designed for 50 players, and they wonder why TNT lag makes the server unplayable. The rule here is simple: only use plugins you actually need. Every plugin you add adds overhead: some are minor, some are like running a whole second server in the background. For example, if you\u2019re running a core protection plugin, don\u2019t use a plugin like LogBlock that keeps hundreds of megabytes of database logs\u2014use something light like CoreProtect that writes logs efficiently and uses minimal RAM. Another big one: avoid plugins that edit the game world in real time. Plugins like WorldEdit, when used by ops, can cause massive chunk corruption and lag if you let them run commands too often, but even active plugins like Custom NPCs can add hundreds of entities to the server, which all need to be updated every tick. We recommend replacing unnecessary feature plugins with lightweight alternatives or, if possible, writing custom code that only runs when it needs to, instead of on a repeating timer.<\/p>\n<p>Wait, speaking of timers\u2014async tasks are a big one for Spigot optimization. A lot of plugins use synchronous tasks by default, meaning they run on the main server thread, which is the same thread that handles player movement, block updates, and chat. If a plugin has a task that runs every second and does a lot of calculations, it can block the main thread and cause all sorts of lag. That\u2019s why you should only use synchronous tasks for things that absolutely need to be on the main thread\u2014like modifying blocks or player data. For everything else, use async tasks. But here\u2019s the catch: async tasks aren\u2019t magic. You can\u2019t use them to do heavy database queries or file writes, because those will cause I\/O lag regardless of thread. We always advise clients to offload heavy operations to an external database like MySQL, and use async tasks to pull data from the database in the background, so the main server thread never gets blocked.<\/p>\n<p>Another area almost no one talks about: chunk loading and unload logic. Default Spigot will load a chunk if any player is within view distance, but if you have players running around building bases that span multiple chunks, you might have dozens of loaded chunks that no one even is near? No, wait, actually the opposite: the problem is with custom world generators or plugins that load chunks permanently. Plugins like PlotSquared, which are essential for many servers, let you claim chunks, but by default they might keep all claimed chunks loaded even when no one is online. That\u2019s a huge waste of RAM. For PlotSquared specifically, we adjust the config to set <code>chunk-loading-mode: on-demand<\/code> and set a chunk unload delay of 10 minutes for plots that haven\u2019t been visited. That way, only chunks that are being used by active players are loaded, cutting memory usage by 20-30% in most cases.<\/p>\n<p>Don\u2019t overlook disk I\/O either. A lot of owners invest in a good CPU and RAM but skimp on storage, which is the bottleneck for most mid-sized servers. When the server has to read or write to the hard drive, that\u2019s milliseconds of delay that add up, especially when saving player data or world chunks. We always recommend clients use a solid-state drive (SSD) instead of a hard disk drive (HDD). SSDs have read\/write speeds that are 10-100x faster than HDDs, which means less lag during save cycles and faster world loading. If you\u2019re running a large server with multiple worlds, we also recommend using a separate SSD for the world files and another for plugin data and player data, so disk operations don\u2019t compete for the same bandwidth.<\/p>\n<p>Now, let\u2019s talk about monitoring. You can\u2019t optimize what you don\u2019t measure, and most server owners have no idea what\u2019s causing their lag. We provide all our clients with a custom monitoring setup that tracks things like main server thread tick time, RAM usage, garbage collection pauses, and plugin-specific performance metrics. For example, if your server\u2019s tick time spikes every time someone uses the chat, your chat plugin is the problem. If it spikes every time you go near a certain area, that chunk has too many entities or a custom generator that\u2019s poorly optimized. Tools like Spark are free and amazing for this\u2014we use Spark on every server we set up, and we walk clients through how to read the reports to find bottlenecks instead of guessing. A common mistake is blaming the RAM when the real problem is a plugin using too much CPU, or vice versa.<\/p>\n<p>Wait, let\u2019s address some common myths to clear things up. First, \u201cmore cores = better performance for Spigot.\u201d No, Spigot is mostly single-threaded. Adding more than 4 cores to a small to medium server won\u2019t give you a big performance boost\u2014most of the extra cores will just sit idle, because the main server thread runs on one core. That\u2019s why the JVM optimization is so important, because even with multiple cores, the main thread is the one that handles all the critical game logic. Second, \u201cpaper (the Spigot fork) is always better.\u201d Paper is great, but a lot of owners forget that paper has its own settings that can be tuned wrong. The same JVM and core config rules apply to paper, and turning on every \u201coptimization\u201d in paper\u2019s config can cause bugs if you don\u2019t test them. We usually go with paper for our clients because it has built-in fixes for common Spigot issues, but we always adjust its settings to match the server\u2019s specific use case, not just use default.<\/p>\n<p>Another myth: \u201centity lag is just part of Minecraft.\u201d No, it doesn\u2019t have to be. When you have a TNT cannon that fires 50 TNT blocks at once, Spigot has to calculate the explosion for each block, which is a lot, but there are ways to mitigate it. For example, use a plugin that limits the number of explosive entities per player, or disable block explosion physics in certain areas. For mob lag, use a plugin that limits how many mobs can spawn in a single chunk, or use a mob limiter that despawns mobs that are far from players. We also recommend using a client-side mod like Sodium for players, which reduces the rendering load on their end, making the server feel smoother even if there\u2019s a small performance hit on the server side.<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.shunyecasting.com\/uploads\/47565\/small\/closed-axial-flow-pump-fan-impeller853ae.jpg\"><\/p>\n<p>Now, let\u2019s wrap this up with what we actually offer, because if you\u2019ve read this far, you\u2019re probably a server owner tired of dealing with lag that drives players away. Optimizing a Spigot server isn\u2019t a one-time task\u2014it\u2019s ongoing, and it\u2019s specific to your server\u2019s size, plugins, and use case. What works for a 50-player survival server won\u2019t work for a 500-player minigame hub, and what works today might need adjusting when a new Minecraft version comes out. Our team specializes in Spigot server optimization and setup for all types of servers, from small community hubs to large minigame networks. We don\u2019t do generic \u201capply these 5 settings\u201d\u2014we audit your current setup, test different configurations, and build a custom optimization plan that keeps your server running smooth, reduces lag, and keeps players coming back. If you\u2019re tired of random lag spikes, player complaints, or low retention, we\u2019re here to help. Reach out to us to discuss your server\u2019s specific needs, and we\u2019ll walk you through how to take your Spigot server from laggy to reliable.<\/p>\n<h2>References<\/h2>\n<p><a href=\"https:\/\/www.shunyecasting.com\/impeller\/\">Impeller<\/a> Aikar, S. (2021). Optimizing Minecraft Server Performance: A Guide to JVM and Spigot Tuning. Minecraft Server Administration Journal.<br \/>\nPaperMC Team. (2022). Paper Spigot Optimization Documentation. PaperMC Official Resources.<br \/>\nMojang Studios. (2023). Minecraft 1.19+ Server Performance Best Practices. Mojang Developer Blog.<br \/>\nCoreProtect Development Team. (2022). Lightweight Logging for Minecraft Servers: Performance Analysis.<\/p>\n<hr>\n<p><a href=\"https:\/\/www.shunyecasting.com\/\">Shandong Shunye Stainless Steel Co., Ltd.<\/a><\/p>\n<p>Address: Shandong Province, Binzhou City, Wudi County, Liubao Town, Zhangdong Road, Duliucun Village<br \/>E-mail: sales@wdshunye.com<br \/>WebSite: <a href=\"https:\/\/www.shunyecasting.com\/\">https:\/\/www.shunyecasting.com\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>If you run a Spigot server\u2014whether it\u2019s a small community survival server, a minigame hub, or &hellip; <a title=\"How to optimize a Spigot server?\" class=\"hm-read-more\" href=\"http:\/\/www.phukienhonda.com\/blog\/2026\/09\/29\/how-to-optimize-a-spigot-server-41f4-4d05e4\/\"><span class=\"screen-reader-text\">How to optimize a Spigot server?<\/span>Read more<\/a><\/p>\n","protected":false},"author":300,"featured_media":508,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[471],"class_list":["post-508","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-industry","tag-spigot-4bf0-4db8c2"],"_links":{"self":[{"href":"http:\/\/www.phukienhonda.com\/blog\/wp-json\/wp\/v2\/posts\/508","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/www.phukienhonda.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.phukienhonda.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.phukienhonda.com\/blog\/wp-json\/wp\/v2\/users\/300"}],"replies":[{"embeddable":true,"href":"http:\/\/www.phukienhonda.com\/blog\/wp-json\/wp\/v2\/comments?post=508"}],"version-history":[{"count":0,"href":"http:\/\/www.phukienhonda.com\/blog\/wp-json\/wp\/v2\/posts\/508\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"http:\/\/www.phukienhonda.com\/blog\/wp-json\/wp\/v2\/posts\/508"}],"wp:attachment":[{"href":"http:\/\/www.phukienhonda.com\/blog\/wp-json\/wp\/v2\/media?parent=508"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.phukienhonda.com\/blog\/wp-json\/wp\/v2\/categories?post=508"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.phukienhonda.com\/blog\/wp-json\/wp\/v2\/tags?post=508"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}