ECS Logging .NET
Elastic Cloud Serverless projects are autoscaled environments, fully managed by Elastic and available on Elastic Cloud. Availability This functionality is generally available and ready for production usage. Serverless interfaces and procedures might differ from classic Elastic Stack deployments. The Elastic Stack includes Elastic's core products such as Elasticsearch, Kibana, Logstash, and Beats. Availability This functionality is generally available and ready for production usage. Unless stated otherwise on the page, this functionality is available when your Elastic Stack is deployed on Elastic Cloud Hosted, Elastic Cloud Enterprise, Elastic Cloud on Kubernetes, and self-managed environments. This documentation corresponds to the latest patch available for each minor version. If you're not using the latest patch, check the release notes for changes.
Serverless
Generally available
Stack
Generally available
ECS logging are integrations for your favorite .NET logging libraries. They make it easy to format your logs into ECS-compatible JSON.
Want to learn more about ECS, ECS logging, and other available language plugins? See the ECS logging overview.
The .NET ECS libraries fall into several categories:
At its core all .NET ECS libraries are powered by Elastic.CommonSchema which strongly types the ECS specification to .NET classes.
This library can be used to map your events to ECS in a typesafe fashion.
var doc = EcsDocument.CreateNewWithDefaults<EcsDocument>();
doc = new EcsDocument();
Lean more about Elastic.CommonSchema.
Our log formatters allow you to change the way various logging frameworks log to IO (file/console) to use ECS json.
Our datashippers integrate with logging frameworks to facilitate sending events (logs) to various off Elastic receivers.
Currently these shippers support Elastic Cloud & Elasticsearch but other outputs are in the works.
All the data shippers utilize Elastic.Ingest.Elasticsearch.CommonSchema to send events to Elasticsearch.
Enrichers can be installed next to Log Formatters and Data Shippers to automatically enrich the ECS json that gets produced.
The libraries reuse the same components that power other .NET libraries from Elastic— ensuring a common way to both configure and monitor Elastic’s .NET libraries.

At its core all data shippers depend on Elastic.Transport to coordinate HttpRequests. This library is also the heart of Elastic’s clients and ensures we share best practices and configuration options.
The data shipper libraries all depend upon the push based ingestion abstractions from Elastic.Ingest.* that presents an easy to use System.Threading.Channels backed method to push events as batches at variable rates to external datasources.