We have one aspx page uploaded in the Document Library with basic html tags(including html and body tag). when we try to open the aspx page it redirects to /_layouts/15/download.aspx page
we have also tried the setting- use the server default(open in browser)/Open in browser in the library advance settings and tried to upload the aspx page using the upload option instead of drag and drop.