You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, ASP.NET Core supports configuration providers for JSON, XML, and INI files. However, YAML is a popular configuration format due to its readability and support for complex data structures. Adding a YAML configuration provider would enhance the flexibility and usability of ASP.NET Core applications, especially for developers who prefer or require YAML for their configuration needs.
Benefits:
Increased flexibility in configuration file formats.
Improved readability and maintainability of configuration files for developers who prefer YAML.
Enhanced support for complex configuration scenarios.
YAML is widely used in various applications and tools, such as Kubernetes and Ansible, making it a valuable addition to the ASP.NET Core configuration system. By supporting YAML, ASP.NET Core can better align with the preferences and needs of a broader developer community.
Yeah, I saw these libs. I would like to minimize dependency on 3rd party libs for core functionality. I believe configuration is a part of application core.
I would like to minimize dependency on 3rd party libs for core functionality.
See this discussion #83313 (comment), generally third party libraries is the way to go when it comes to YAML. #83313 is the prerequisite, and other similar proposals before that (which were not accepted).
As much as I'd love to see a native yaml parser in .net, I think since json is a subset of yaml, probably better to just use the json format for this specific purpose.
That being said most people prefer yaml for configuration files.
Exactly! For a long time aspnet was using Newtonsoft JSON library. Then they decided to implement own JSON parser. Why not implement own YAML if it is so popular?
Activity
dotnet-policy-service commentedon Oct 24, 2024
Tagging subscribers to this area: @dotnet/area-extensions-configuration
See info in area-owners.md if you want to be subscribed.
am11 commentedon Oct 24, 2024
Currently, runtime libraries do not offer built-in support for YAML serialization, which is the prerequisite of this feature request. However, there are community-driven YAML serialization packages like YamlDotNet, which serve as the foundation for various extensions, such as NetEscapades.Configuration.Yaml (https://www.nuget.org/packages/NetEscapades.Configuration.Yaml) and SharpDotYaml.Extensions.Configuration (https://www.nuget.org/packages/SharpDotYaml.Extensions.Configuration). Do these options meet the requirements of your use case?
stasberkov commentedon Oct 25, 2024
Yeah, I saw these libs. I would like to minimize dependency on 3rd party libs for core functionality. I believe configuration is a part of application core.
am11 commentedon Oct 25, 2024
See this discussion #83313 (comment), generally third party libraries is the way to go when it comes to YAML. #83313 is the prerequisite, and other similar proposals before that (which were not accepted).
StephenHodgson commentedon Dec 11, 2024
As much as I'd love to see a native yaml parser in .net, I think since json is a subset of yaml, probably better to just use the json format for this specific purpose.
That being said most people prefer yaml for configuration files.
rosebyte commentedon Mar 6, 2026
Triage: we see there are several 3rd party packages.
StephenHodgson commentedon Mar 6, 2026
3rd party isn't 1st party. IMHO YAML should be since a majority of CI/CD and automation and config as code implementations are YAML.
stasberkov commentedon Mar 6, 2026
Exactly! For a long time aspnet was using Newtonsoft JSON library. Then they decided to implement own JSON parser. Why not implement own YAML if it is so popular?