There are various reasons for why you may encounter a ‘Server error in ‘/’ ap­plic­a­tion’. Often the error message provides a bit more detail of what’s wrong. In most cases, the server-side error message is related to IIS (Internet In­form­a­tion Services) or ASP.NET.

Re­quire­ments

  • Cloud Server running Windows Server 2012
  • ASP.NET installed
VPS Hosting
VPS at an un­beat­able price – and better than ever
  • NEW: Flexible scaling with VM-cloning, load balancing, new storage options and more
  • Unlimited traffic and >99.99% avail­ab­il­ity
  • 24/7 expert support and your own personal con­sult­ant

Restart IIS

The ‘Server error in ‘/’ ap­plic­a­tion’ can happen if IIS needs to be restarted. You can restart IIS from the IIS Manager. From your Remote Desktop con­nec­tion, click the ‘Start’ button in the lower left-hand corner and select ‘Ad­min­is­trat­ive Tools’.

Image: Windows panel ‘Administrative Tools’
Windows panel ‘Ad­min­is­trat­ive Tools’

Click ‘Internet In­form­a­tion Services (IIS) Manager’ to launch the IIS manager.

Image: Administrative Tools: Internet Information Services (IIS) Manager
Ad­min­is­trat­ive Tools: Internet In­form­a­tion Services (IIS) Manager

Select the affected server from the left-hand panel.

Image: IIS manager: server selection
IIS manager: server selection

On the right of the IIS Manager, click ‘Restart’ to restart IIS.

Image: IIS manager: Restart
IIS manager: Restart

Update the URL

Under some cir­cum­stances, a 404 error may be displayed as ‘Server error in ‘/’ ap­plic­a­tion’. When this is the case, the error de­scrip­tion in the browser will clarify that the error has occurred because the file is missing or has been renamed.

Image: http 404 error message
http 404 error message

To fix this problem, correct the URL in the link that triggers this error.

Cloud Backup powered by Acronis
Mitigate downtime with total workload pro­tec­tion
  • Automatic backup and easy recovery
  • Intuitive schedul­ing and man­age­ment
  • AI-based threat pro­tec­tion

Add the MIME type

If you are accessing a file with a file extension that does not have per­mis­sions to be run on the server, you will see the ‘Server error in ‘/’ ap­plic­a­tion’ along with the ex­plan­a­tion that ‘This type of page is not served’.

Image: Message ‘This type of page is not served’
Message ‘This type of page is not served’

When exploring a solution to a ‘Server error in ‘/’ ap­plic­a­tion’, first ensure that you are using the correct file name. The ‘Server error in ‘/’ ap­plic­a­tion’ can occur if there is a typo in the file extension, for example a file or URL that ref­er­ences test.htl instead of test.html.

If the file name is correct, then you may need to add the MIME type to the server. MIME stands for Mul­tipur­pose Internet Mail Ex­ten­sions. The MIME type is used to indicate what type of document it is. In the example, we are trying to run a file called Hel­lo­World.cshtml. The file extension .cshtml is not as­so­ci­ated with any MIME type by default on Windows 2012.

You can add the MIME type in the IIS Manager. To open the IIS Manager, from your Remote Desktop con­nec­tion, click the Start button in the lower left-hand corner and ‘Ad­min­is­trat­ive Tools’.

Image: Windows panel ‘Administrative Tools’
Windows panel ‘Ad­min­is­trat­ive Tools’

Click ‘Internet In­form­a­tion Services (IIS) Manager’ to launch the IIS manager.

Image: Administrative Tools: launch IIS manager
Ad­min­is­trat­ive Tools: launch IIS manager

Click the server in the left-hand panel.

Image: IIS manager: select server
IIS manager: select server

Now click ‘Sites’.

Image: IIS manager: ‘Sites’
IIS manager: ‘Sites’

Then click on your domain. In the central panel, double-click ‘MIME Types’.

Image: IIS manager: symbol ‘MIME Types’
IIS manager: symbol ‘MIME Types’

Under the ‘Actions’ column on the right, click ‘Add’.

Image: IIS manager: add MIME types
IIS manager: add MIME types

In the pop-up window which appears, fill in the ‘File name extension’ and ‘MIME Type’ fields, then click ‘OK’.

Image: IIS manager: add MIME type window
IIS manager: add MIME type window
Note

You may need to do an Internet search to find the correct MIME Type for your file extension.

Verify the .NET Version

Some programs, features, and file types will only run under certain versions of .NET.

You can also check your .NET version from the IIS Manager. To open the IIS Manager from your Remote Desktop con­nec­tion, click the ‘Start’ button in the lower left-hand corner and then select ‘Ad­min­is­trat­ive Tools’.

Image: Windows panel ‘Administrative Tools’
Windows panel ‘Ad­min­is­trat­ive Tools’

Click ‘Internet In­form­a­tion Services (IIS) Manager’ to launch the IIS manager.

Image: Administrative Tools: Internet Information Services (IIS) manager
Ad­min­is­trat­ive Tools: Internet In­form­a­tion Services (IIS) manager

Click to expand the server in the left-hand window panel.

Image: IIS manager: server selection
IIS manager: server selection

Click on ‘Ap­plic­a­tion Pools’.

Image: IIS manager: ‘Application Pool’ among selected servers
IIS manager: ‘Ap­plic­a­tion Pool’ among selected servers

Right-click on the Domain Name and click on ‘Basic Settings’.

Image: IIS manager, Application Pools: contextual menu, ‘Basic settings’
IIS manager, Ap­plic­a­tion Pools: con­tex­tu­al menu, ‘Basic settings’

In the pop-up window which appears, select the .NET version from the drop-down menu, then click ‘OK’ to confirm your choice.

Image: IIS manager, Application Pools: select .NET version
IIS manager, Ap­plic­a­tion Pools: select .NET version

Reviewer

Go to Main Menu