Your WP Server Cache Might Be Costing You Leads

PHP Laravel coding. Can be used as background
Home » Blog » Your WP Server Cache Might Be Costing You Leads
Free Web Marketing Consultations

Helping B2B Technology Companies Increase Their Lead Volume.
Serving: IT, MSP, Cybersecurity, Software Dev, SaaS, ISV, VARs & More.

Table of Contents
    Add a header to begin generating the table of contents

    Over the past 3 months I’ve been battling an infuriating and troubling issue. Some of my WordPress site’s forms were not submitting! But not all the time, just some of the time. A developer’s worst nightmare. This was having a real impact on lead generation efforts as this was most frequently occurring on downloadable PDFs or “lead magnets” where people can exchange an email address for a piece of premium content. Check out our offers and downloads page for some examples. I first discovered this issue after looking in my Google Analytics and spotting people hitting the same offer download page 5+ times in a single day. Since these pages receive relatively low traffic, it’s rare for them to get more than 1 hit per day. Seeing analytics data with that many hits points to someone refreshing the page repeatedly, probably out of frustration. In this post, I’ll dive into what the findings were of my investigation there, what the fix was, and raise awareness on a caching issue that’s probably costing businesses a lot of potential inbound leads from their contact forms.

    Cryptic 403 Error On Form Submits In WordPress

    So the specific page that kicked all this off was our MSP Industry Keywords Download, a list of 30 keywords with documented conversion history on paid search advertising efforts. This page is on a WordPress website and uses Beaver Builder subscribe forms to capture email addresses in exchange for the download. Eventually, I discovered the page was returning a 403 error on submit but it took a little while to get there.

    The first time I investigated this issue I was unable to identify anything because I was signed in when troubleshooting. When you are signed in to the backend of WordPress most hosting providers will configure rules to bypass the cache when you’re viewing pages that are in edit mode. Therefore the page looked normal to me. I know that sometimes behavior can be different between signed-in and signed out so I also tested with a signed-out view, but was unable to replicate it because I had been re-publishing the page during troubleshooting. Re-publishing a page triggers a cache refresh, which will be important in a moment. I figured my analytics anomaly was maybe just a strange bot and let the issue go for the time being.

    The Kindness of Strangers Helps Identify 403 On AJAX Call In WordPress

    Not long after this initial troubleshooting session I had a kind stranger reach out to me, Sean from Crown Computers who said they had tried to download the lead magnet, but were unable to and also had a few questions about SEO for their MSP. I immediately opened up the browser and tried again only to discover that the form was getting stuck in a processing state and never actually submitting. When I inspected the Chrome Developer tools a 403 forbidden error was showing on admin-ajax.php. AHA! Now I had a trail to bloodhound down.

    Troubleshooting the 403 Error On WordPress

    An HTTP 403 error on WordPress means “forbidden”, the server is rejecting the call for a security reason. It’s a bit ambiguous, but happens often enough that there are a few blogs out there on the subject.

    Most of these blogs recommend the following potential culprits:

    • Security plugins blocking AJAX calls
    • File permission settings on your host
    • Corrupt HTACCESS files
    • VPNs or user PC-specific issues

    None of these worked! I spoke to Beaver Builder (page builder vendor), Antispam Bee (security plugin vendor), Kinsta (my hosting provider), and Active Campaign (CRM vendor that the subscribe form is integrated with) all of whom were very helpful, but unable to help me figure out what was happening. They recommended doing some standard WordPress troubleshooting steps like disabling plugins and clearing your cache, which I did. I noticed that when I cleared my cache, this time around the issue went away and I was unable to reproduce it. I had to abandon collaboration with vendors, even a GitHub ticket trying to figure out what was going on. The issue just magically went away and I couldn’t bring it back. Maddening!

    3rd Time The Charm For Identifying Cause Of 403 Error On Form Submissions In WordPress

    I knew that despite this issue magically disappearing a couple of times now, it would be back and that it was somehow related to caching. I monitored my site for 1-2 months, periodically checking the lead magnet page and trying to submit the form and replicate the issue, to no avail. Every time I checked on it, it was working fine, until once again I looked at my analytics and saw 7 hits on the same day to the page without any sort of conversion. I popped open the browser and tried to submit the form and the pesky 403 error was back. This time I did some more advanced troubleshooting in the Chrome developer tools and got a firm understanding of the call stack for which this error was happening down to line numbers and scripts involved. I narrowed it down to Beaver Builder as the most likely vendor involved and went back and forth with them where we were able to identify the issue. Shoutout to Pross and the Beaver Builder team for their patience and dynamite support team! If you’re looking for a page builder for your WordPress site, which I highly recommend for startups and small businesses, you can sign up for them using our affiliate link. Anyways, the issue we discovered was due to WordPress caching the nonce that gets submitted along with the form for longer than the nonce’s lifespan.

    What Is A Nonce In WordPress?

    A nonce is short for “number used once” and is simply a unique identifier for a request that verifies its authenticity. A nonce passed along with requests, such as AJAX form submits, helps defend against a number of common cyber attacks and keeps your information secure. See this codex entry on nonces for more information.

    Understanding The Relationship Between Nonce Expiry And Cache Expiry

    A WordPress nonce, once generated, is valid for a minimum of 12 and a maximum of 24 hours depending on a couple of factors. Most forms will submit their nonce via a hidden field value which is cached along with all the other HTML of a page by many WordPress hosting providers. If you’re like me and a lover of all things SEO and page speed, you want to maximize the number of speedy visits you can generate on your website. You or your host may have your cache expiry set to a duration longer than 12 hours. If this is the case and you’re using forms on your website that rely on WordPress nonces you are likely encountering issues where people cannot submit forms your forms to either contact you or to subscribe to your email list. In my case, I had a 7-day cache expiry set so I was only encountering this issue on days 2,3,4,5,6 after publishing a new version of the page. Since I was only checking for the issue a couple of times per month to look for it, I was likely past the 7-day cache expiration and getting a hard reload and successful form submission with an active nonce. Day 1 and Day 7+ would make everything appear to be working correctly. Once this issue was discovered I shortened my cache expiry to 8 hours, which is below the 12-hour guaranteed nonce validity window in WordPress, and resolved this issue for good.

    Note, that nonce timelines can be customized, so if you’re working on a sophisticated WordPress site, these times can change, but the default settings come with a 12-hour minimum and 24-hour maximum lifespan.

    Further Reading: WordPress Caching And Nonce Lifespans

    Wrapping Up

    This was a complex issue, that was only presenting under very specific circumstances. It was one that could easily elude even experienced developers due to its intermittent nature. I hope you enjoyed this post and hope that it helps save someone some time in the future. Thanks for reading.

    Share This Article
    Posted in:
    Tagged:

    Hunter Nelson

    Hunter is the founder and president of Tortoise and Hare Software, a digital marketing agency for the technology sector and other lead generation oriented businesses. Hunter has more than 10 years’ experience building web applications and crafting digital strategies for companies ranging from scrappy startups to Fortune 50 household names. When not on the clock, you'll find him spending time with his family and pups, relaxing on the beach, or playing competitive online video games. See for more.

    Leave a Comment





    Recent Blog Posts

    SEO Not Working: Here’s Why

    Lately I’ve been getting on more and more calls lately with people saying something along the lines of “we’ve been doing SEO or inbound for 6 months, 12 months, or…

    Why SEO Investments Help Your MSP Weather a Recession and Keep the Door Open for New Opportunities

    What happens to your pipeline when the phones go quiet, inboxes stay cold, and paid ads stop converting? That’s not a hypothetical. It’s what happens in a recession. Budgets freeze.…

    MSP Marketing – How to Build a Strategy That Works

    Let’s be honest—most MSP marketing doesn’t work.Not because the tactics are bad, but because they’re unaligned. What looks like a marketing problem is often a strategy problem in disguise. Most…

    The 10 Best MSP SEO Agencies To Help You Grow Organic Traffic

    If you’re searching for SEO agencies for MSPs, the list of generalists can feel endless—and underwhelming. Most SEO providers don’t understand the managed services space, much less the buyer behavior,…

    Why Your MSP’s Online Marketing Efforts Are Failing

    If you’re leading an MSP and investing in online marketing, you’re probably feeling a growing sense of frustration. You’ve put money into websites, content, ads—even hired an agency or two…

    What Makes a Great MSP Website? 5 Examples You Should Follow

    Your MSP website is more than just an online brochure—it’s a powerful tool for attracting and converting potential clients. But what makes a website truly effective in the competitive managed…

    Related Blog Posts

    WordPress Out OF Memory Exceptions

    Recently I’ve been dabbling in programmatic SEO. I got an idea of rolling out a landing page to attract search engine traffic from every major city in the United States…

    How To Generate More MSP Website Leads With A Primary Call To Action

    In today’s digital age, your Managed Service Provider (MSP) website serves as the cornerstone of your online presence. It’s the virtual gateway for potential clients to explore your services, expertise,…

    Why We Recommend Page Builder Websites For Startups

    If there’s one word that characterizes startup companies it’s instability. I see this across service providers like IT companies and product companies like SaaS startups. Small and growing companies oftentimes…

    Why A B2B Website Should Cost $10,000+

    In today’s post, I want to break down a common misalignment between B2B website purchasers and agencies when it comes to website development. Website pricing, like all goods and services,…

    The 5 Second Test For PPC Landing Pages

    I’ve been having a lot of conversations recently about optimizing websites for lead generation and explaining a concept called the 5 second test. The 5 second test is a design…

    Why You Should Keep Your SaaS Installed On A Subdomain

    More than a few SaaS founders start out with a technical background, looking to parlay their coding skills into a product and build a business off it. Their surplus of…

    Top Blog Content

    The Ultimate Guide To MSP SEO

    Search Engine Optimization (SEO) is one of the most important ways to attract new business for mid-market managed service providers (MSP). If you look at MSPs that have achieved any…

    The Ultimate Guide To Paid Search On Google Ads For Managed Service Providers

    Generating leads for your MSP can be a challenge. You spend so much time managing employees, making sure customer support tickets are answered, procuring hardware, and defending against cyber threats,…

    The Ultimate Guide To MSP Website Optimization

    A well-optimized website is essential for Managed Service Providers (MSPs) looking to scale their business, attract more leads, and achieve a lucrative exit. A lot of MSPs check a few…

    The Ultimate Guide to Hiring an MSP Marketing Agency

    Are you one of the many MSPs struggling to attract new clients consistently? According to research conducted by MSP Dojo, a leading MSP sales consulting firm, approximately 85% of MSPs…

    The Ultimate Guide To Setting A Marketing Budget For IT Companies

    Many IT companies get their start as a one-man operation and rely almost exclusively on word of mouth, referrals, and other organic offline means to get past their initial growth…

    Featured Review of Tortoise and Hare

    ryan drake president nettech consultants
    R.D.
    President Florida Based MSP

    Tortoise and Hare has been a key partner in our MSP's growth. Over the year's we've worked together they've helped our MSP dramatically increase our website traffic, and build a steady stream of leads sourced from our website and advertising efforts. Over that time, we've been able to raise our base customer size, build economies of scale to more efficiently service customers, and expand into new markets.