0👍
✅
The HTML encoding engine will only safelist the basic latin alphabet,to widen the characters treated as safe by the encoder, try to add below code to your Program.cs:
builder.Services.AddSingleton<HtmlEncoder>(HtmlEncoder.Create(allowedRanges: new[] { UnicodeRanges.BasicLatin, UnicodeRanges.Arabic }));
Source:stackexchange.com