Skip to content

HTTP 405 Method Not Allowed to default Blazor Server template – breaks Bing/Google crawl #64115

@vsfeedback

Description

@vsfeedback

This issue has been moved from a ticket on Developer Community.


[severity:It's more difficult to complete my work]
Product/Version
Visual Studio 2022 (17.14.16) – “Blazor Server” template, .NET 9
Problem Description
The ASP.NET Core pipeline generated by the default Blazor Server template rejects HTTP HEAD requests with status 405.
Search-engine crawlers (Bingbot, Googlebot) rely on HEAD to discover page availability; when they receive 405 they report “Crawl error – page cannot be displayed”, preventing site indexing even though the same URL returns 200 for GET.
Repro Steps
File ▸ New ▸ Project ▸ Blazor Server (interactive).
F5 / dotnet run → site listens on e.g. https://localhost:5000/.
In terminal run:
curl -I -X HEAD -A "bingbot" https://localhost:5000/
Response:
HTTP/1.1 405 Method Not Allowed
Server: Kestrel
Allow: GET, POST
Expected Behavior
HEAD should return 200 (same as GET) so crawlers can proceed.
Actual Behavior
405 is returned; Bing/Google report crawl failure.


Original Comments

Feedback Bot on 10/20/2025, 07:35 AM:

We have directed your feedback to the appropriate engineering team for further evaluation. The team will review the feedback and notify you about the next steps.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Author: Migration Bot 🤖The issue was created by a issue mover bot. The author may not be the actual author.area-blazorIncludes: Blazor, Razor Components

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions