Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is it possible to change HTML title with SwashBuckle and Swagger UI

We have many services, which use SwashBuckle / Swagger UI to expose REST methods.

It can often be annoying when you have several of them open in tabs in a browser that you cannot immdiately see the service name from the tabs. At least not without switching to that tab

Is it possible to change the HTML title from SwashBuckle?

enter image description here

like image 213
Torben Nielsen Avatar asked Jan 23 '26 07:01

Torben Nielsen


1 Answers

Yes, Simply change document title

app.UseSwaggerUI(option => 
{ 
    ...
    option.DocumentTitle = "Your Title"; 
    ...
});
like image 87
MrMoeinM Avatar answered Jan 24 '26 19:01

MrMoeinM



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!