© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
C#C
C#•2y ago•
26 replies
Suraj Kumar

✅ Enable CORS

I have added cors enable funtionality but the issue still persists.
builder.Services.AddCors(options =>
{
options.AddPolicy("AllowAll", builder =>
{
builder.AllowAnyOrigin()
.AllowAnyHeader()
.AllowAnyMethod();
});
});

app.UseCors("AllowAll");
app.UseAuthentication();
app.UseAuthorization();
app.MapControllers();
Screenshot_2024-06-18_114559.png
C# banner
C#Join
We are a programming server aimed at coders discussing everything related to C# (CSharp) and .NET.
61,871Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

is it possible to enable cors in net framework?
C#CC# / help
4y ago
❔ CORS error
C#CC# / help
3y ago
❔ !CORS ERROR!
C#CC# / help
3y ago
❔ CORS error
C#CC# / help
4y ago