Modify WordPress Search Query to Include Custom Fields

One of my favorite clients was one of the first projects where I was really able to dig to into the wonderful world of ACF. However before site launch (back in 2014) – we discovered that native WP search functionality only searched content loaded into the content editor – and there is a lot of content outside of this = because search is such an important part of the website we had to come up with a solution and eventually settled on Custom Google Search – this worked – it was robust we didn’t have total control over the front end , but close enough. However in May this went out – they were going to add ads – which is touchy for a non-profit that has a very controlled message – we needed to figure out a solution. Welp, 3 years later, thanks to this super straight forward tutorial from adam balee, i was able to revert to the native wp search functionality and instead alter / expand the query to search custom fields – it worked like a charm! https://adambalee.com/search-wordpress-by-custom-fields-without-a-plugin/