Hugo webapp does not render correctly on Azure

Armin Sproll 21 Reputation points


I have a website build with hugo that works correctly hosted by my provider

I am trying to put this site on Azure as static webapp and have deployed it from Azure DevOps. I also tried static webapp in Azure container. Both with the same result, the site does not render correctly:

Any ideas what is wrong here?


Azure Static Web Apps
Azure Static Web Apps
An Azure service that provides streamlined full-stack web app development.
811 questions
0 comments No comments
{count} votes

Accepted answer
  1. ajkuma 23,641 Reputation points Microsoft Employee

    @Armin Sproll ,

    If you view the source of your site on Azure, you can see that it is referencing the CSS files from your other site.

    Please review the source below. [screenshot below and I have also attached 192292-reviewcode notepad file]
    source view

    Because Azure Static Web Apps enforces HTTPS by default, your site is loaded securely and is accessing those CSS files which are only available over an insecure HTTP connection. The browser will not allow this.

    You should be able to fix this by changing the baseUrl in your Hugo configuration to the HTTPS URL of your static web app.

    // cc: @Anthony Chu - MSFT


    To benefit the community find the right answers, please do mark the post which was helpful by clicking on Accept Answer’ & ‘Up-Vote’.

0 additional answers

Sort by: Most helpful