Best Wordpress performance

Hi guys! I would like to know what’s the best way to create a droplet with the best setup to secure and have the best performance for a wordpress website. I want my wordpress to load fast (that’s why I chose DigitalOcean over a shared hosting). Also I would like to know if its possible to install or have more than 1 website in a droplet.

Best regards!

Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

Caching. Everything can be cached, even just for a few seconds. I could write an essay about the different caching strategies, but it all depends on how comfortable you are with different tools and what you need, as opposed to what you want.

My tool of choice is Varnish and Redis, but you generally want to understand some of the fundamentals of HTTP when dealing with Varnish, there are lots of gotchas. Using VCL (Varnish Configuration Language) that you found somewhere on Google is going to bite you in the ass, mark my word. So going down that route, make sure you take the time to understand how Varnish works.

You can (in theory) has as many webpages as you have disk space and memory to serve. There isn’t a definitive answer to how many, but more than one, sure. More than ten, probably. All depends on the resources available and activity.

Security? Keep things updated, don’t use plugins that aren’t vetted and regularly receives updates. For things like Wordpress this is absolutely crucial. Exploits to the “core” are very rare, and when they happen patches are always right around the corner. A (usually) safe option is to turn on unattended upgrades (for the distro of choice) and make it apply security patches automatically. You can also use tools like needrestart to make sure that no processes are running older and vulnerable code.

When it comes to unattended upgrades you are trusting that someone know what they are doing. For most distros that is an assumption you can safely make when it comes to security. For regular updates it can be smart be more careful. But I doubt you’d have any issues.