Technically this isn’t a pre-purchase question as I’ve already purchased ACF Pro a long time ago (and am so very much in love with it, seriously the best plugin in existence!).
So I’m building a website that I suppose is more of a web application, or at least it’s quickly becoming one. I’m a little worried that WordPress and ACF might not be the best choice, though. I’m not super knowledgeable on the limitations of performance and scalability with WP and ACF and I’d love to hear the opinions of some experts.
Basically, my website is a database of many different custom post types (class, race, creature, item, etc., for RPGs). Each post uses a template made up of lots of ACF fields (average # of fields is ~30, one post type uses 60!). So far, it runs smoothly on both my local and live server, but it’s also not launched to the public yet so I have no idea how it will hold up in a stress test. If you’d like to check the site out, it’s https://draconic.io – only a few sections require a login, but you can get a feel for it without that. The goal is to eventually combine all the features of sites like https://dndbeyond.com and https://worldanvil.com among others.
Is it feasible to build a website like this for a large scale? Or am I going to hit a roadblock with performance and scalability issues and realize I wasted all my time and need to start over with something like Python instead of WP?
This answer is specifically about the front end of a site, I do not get overly concerned with the performance of the admin.
The issue of scalability is not specific to ACF itself, but how it is used. What type of DB queries you’re trying to force WP to do and many other factors.
Inherently, ACF will not have an effect on scalability.
Beyond that there are two many variables and too many ways that it can be used in a way that will effect site performance and most of these have to do with the number of DB queries and how the data is being queried.
Making WP and ACF scalable requires understanding how both work, what could cause bottlenecks and either finding alternatives or mitigating them. Again, the possibilities are just too numerous to list them all.
I will give one example. The ACF image field. Many developers set the image field to return an image array that contains a lot of information that will likely never be used. ACF must do a lot of extra queries to get all of this information. This is probably fine on a small site or if there is only a single image on the page, but if there are many images to be shown then it’s going to slow things down. It is more efficient to return the image ID and then to do the work of getting only the information about that image that you actually need without depending on ACF to do the work. You may have 15 image sized defined in WP, ACF does not know that you really only need information about 2 or 3 of those image sizes, so it gets everything.
I will say one final thing, most of the code that you will find for ACF in the wild does not take these issues into account. Even a lot of the code I post here does not take these issues into account because I attempt to answer the question being asked without injecting my own opinions, though once in a while I will suggest alternatives.
In my own code, unless I am pressed to do something in a hurry I am always asking these questions: What is this doing? How is it doing it? Is this the most efficient way to do it?
The topic ‘Question about scalability’ is closed to new replies.
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!