Google and Search Engines are indexing my forms
04 November 2025 — Dave Cheong
I've noticed in Google Search Console that Google has been unable to index some of my pages. Here's a screenshot showing pages that are Crawled - currently not indexed
CleanShot 2025-11-04 at 17.35.31.png
Upon inspection, it turns out the URLs that have been failing are my comment creation forms and not actual pages.
CleanShot 2025-11-04 at 17.39.13.png
This was a complete surprise to me, because the forms are coded with a POST method. I naturally assumed the Googlebot wouldn't index or follow these—but that assumption turns out to be incorrect.
CleanShot 2025-11-04 at 17.41.23.png

Why Google tries to index a POST form

When Google tries to index a POST form (like a comment submission form), it’s usually because the Googlebot has discovered the form’s URL and thinks it might lead to valuable content. It'll try to index it unless it's been explicitly told not to.
In essence, be aware of the following:
  1. Form action is crawlable (and linked somewhere)
    1. Google can "see" a form if it's in the HTML code
    2. Even if it’s a POST, Google may still attempt to treat it like a GET request to see what’s behind it — since it doesn’t actually submit forms with arbitrary data
  2. No clear signal that it shouldn’t be indexed
    1. If the form or its action URL doesn’t have noindexnofollow, or isn’t blocked via robots.txt, Google assumes it might contain content
    2. Example: /comments could be interpreted as a comments listing page, not just a submission endpoint
  3. Shared URL between view and submission
    1. If the form posts to the same URL that displays the comment list (e.g., /post/123/comments), Googlebot thinks it’s a normal page worth indexing
  4. The site’s internal linking exposes the form action
    1. Sometimes templates or components include <a href="/comments">Leave a comment</a> or use the action URL in a data-action attribute — both of which can be picked up by crawlers

How to stop Google from indexing POST forms

Here are safe, SEO-friendly approaches:

Block the endpoint via robots.txt

This stops Googlebot from fetching that URL. You will have to list all paths that you want to prevent crawling. Note that this prevents crawling, but not indexing, if the URL is already known. Use noindex as well if possible.

Add a <meta name="robots" content="noindex, nofollow"> header to the response

If /comments ever returns HTML, include the following in the response:
But if the URL doesn't return meaningful HTML, you can add a HTTP response header explicitly telling the Googlebot not to index and not to follow:

Separate “display” and “submission” URLs

In the design of urls, separate the urls that display and create.
  • Use /post/123 for displaying comments associated with a given post
  • Use /api/comments (or /post/123/comments) for form submissions

Ensure the form action isn’t accidentally linked

Finally, avoid having code like this which links to the form submission URL:

Why is this important?

Getting this right prevents Google from wasting crawl budget, indexing junk URLs, and hurting your site’s SEO quality signals — it keeps your indexed pages clean, relevant, and user-focused.
If Google is indexing your comment submission form (and similar low-value URLs), it can hurt your SEO in a few key ways:
  1. Wasted crawl budget – Google spends time crawling form endpoints instead of your real content pages, so important pages might get crawled or updated less often.
  2. Thin or duplicate content – If those form URLs return little or no meaningful content, Google sees them as “thin pages,” which can lower your site’s overall quality score.
  3. Index bloat – Having many low-value URLs in the index dilutes your site’s relevance and makes it harder for Google to understand which pages matter.
  4. Poor user experience in search results – A user might click through from Google to a blank form or “method not allowed” page, which increases bounce rate and signals low quality.

Comments (0)