elmah.io Installation Quick Start

Welcome to the quick start installation guide. Here you will find a quick introduction to installing elmah.io. For the full overview, read through the individual guides by clicking a technology in the left menu.

ASP.NET / MVC / Web API

Install the Elmah.Io NuGet package:

Install-Package Elmah.Io

During the installation, you will be asked for your API key and log ID.

For more information, check out the installation guides for WebForms, MVC and Web API. There is a short video tutorial available here:


ASP.NET Core

Install the Elmah.Io.AspNetCore NuGet package:

Install-Package Elmah.Io.AspNetCore

Once installed, call AddElmahIo in the ConfigureServices-method and UseElmahIo in the Configure-method (both in the Startup.cs file):

public void ConfigureServices(IServiceCollection services)
{
    services.AddElmahIo(o =>
    {
        o.ApiKey = "API_KEY";
        o.LogId = new Guid("LOG_ID");
    });
    ...
}

public void Configure(IApplicationBuilder app, IHostingEnvironment env, ILoggerFactory fac)
{
    ...
    app.UseElmahIo();
    ...
}

Make sure to insert your API key and log ID.

For more information, check out the installation guides for ASP.NET Core and Microsoft.Extensions.Logging.

JavaScript

Install the elmah.io.javascript npm package:

npm install elmah.io.javascript

Reference the installed script and include your API key and log ID as part of the URL:

<script src="~/node_modules/elmah.io.javascript/dist/elmahio.min.js?apiKey=YOUR-API-KEY&logId=YOUR-LOG-ID" type="text/javascript"></script>

For more information, check out the installation guide for JavaScript.


This article was brought to you by the elmah.io team. elmah.io is the best error management system for .NET web applications. We monitor your website, alert you when errors start happening and help you fix errors fast.

See how we can help you monitor your website for crashes Monitor your website