Your data. Anywhere you go.

New Relic for iOS or Android

Download on the App Store    Android App on Google play

New Relic Insights App for iOS

Download on the App Store

Learn more

Close icon

.NET Monitoring


New Relic supports all versions of ASP.NET MVC, including the latest version 4.5. In an ASP.NET MVC application, each HTTP request is typically associated with a controller method. When viewing web transaction traces, you’ll see each transaction named after class and controller, like Account.Login. You can also drill down through the trace to identify where your application is spending the most time.

Slow SQL Queries

New Relic counts how often you access your database through common database provider libraries such as SqlClient for SQL Server, Oracle.DataAccess, and the Microsoft Enterprise Library Data Application Block. Additionally, we capture a SQL explain plan for slow SQL queries on both MySQL and MSSQL.

ASP.NET Web Forms and XML Web Services

Although the latest releases of ASP.NET have featured MVC improvements, many .NET developers continue to work with traditional Web Forms. New Relic fully supports Web Forms, and our ASP.NET support goes all the way back to version 2.0. All web transactions will be named using your Web Form's page name, such as "BlogEngineWeb/posts/posts.aspx".

Since Web Forms applications use pre-build controls whose ViewState size can lead to slower page load times, it’s common to create simplified XML Web Services using the [WebMethod] attribute on server-side page methods and then call those methods using AJAX. New Relic records web transactions using these attributed methods. For example, you might see "/BlogEngineWeb/admin/AjaxHelper.aspx/LoadBlogs" as a transaction representing a request to the XML Web Service named "LoadBlogs".

As with all slow web transactions monitored by New Relic, you can drill down within the web transaction to see a detailed trace of the functions called and evaluate their transaction duration during execution.


The ASP .NET Web API makes it ridiculously simple to build a rich HTTP service that can enable the delivery of data to an array of client applications. The Web API is considered to be the ideal platform to build RESTful services for .NET developers. Building a service layer has never been easier; developers can use the Web API with Entity framework and the IQueriable interface on controller actions to allow the entity set to be queried using ODATA syntax. All of these actions can be instrumented by the New Relic .NET agent.


The Web API framework, like most frameworks that allow developers the ability to create services that follow RFC2616 (the HTTP 1.1 specification), use convention over configuration. Being able to differentiate between controller actions for any given endpoint is critical in troubleshooting, optimization, and improving your overall analysis and understanding of how consumers are using your API.

The .NET Agent provides a transparent view into each controller action and monitors the slow transaction segments with their stack traces. The transaction tracing provided by New Relic helps you identify if the bottleneck is in your action, your database, in the request from the client application (if you're using Cross Application Tracing), or in request queuing. Regardless of whether your API controllers inherit from the EntitySetController or the basic APIController, you'll be able to see end-to-end transaction data for each API call when using New Relic.

SQL Queries

Much like Windows Communication Foundation (WCF), SOAP web services and home-grown web-based APIs all face a common danger--a sub-par contract or an exploitable bug can purposefully or inadvertently cause you trouble.

One of the areas where an API can cause the most damage is with your data. APIs can be real troublemakers in this area because you never know exactly how your consumers will be using your API. Without proper countermeasures or thresholds in place, you might find that connection pool exhaustion or n+1 issues are transpiring with no good way of pinpointing why or where.

With the awesome flexibility of Entity Framework, ODATA syntax, and even LINQ, your data and database will be used in some amazing and unexpected ways. New Relic gives you the complete visibility you need on your ASP .NET Web API so that if you face one of these data problems you'll be able to quickly identify it. The .NET Agent will report on how many connections a transaction creates, all database queries that occurred in a given transaction, and even give you explain plans on the really slow transactions to help you optimize your database.


Developers who stand on REF2616 depend on proper HTTP status codes to tell them when they have done something wrong when calling a web-based API. They also use things like headers in combination with those status codes to tell them what to do when something goes wrong. For example the API could respond with a 410 GONE, telling the consumer that the resource is permanently gone and should be deleted on their side.

On the other side of this equation, it is critical for the API developer to know how consumers are using the API and if they’re experiencing any issues. New Relic helps you to identify both the unhanded API exceptions as well as errors that occur during communication with the client. Status codes like 400's, 415's and 405's are caught and reported by the .NET Agent. New Relic helps you understand how consumers are using your Web API, as well as help you communicate with them on better ways to use your service.

Sign Up for New Relic

Back to top icon