dotnet-csharp-coding-standards

Define C# naming, file layout, and style conventions for .NET projects.

1|Updated Feb 22, 2026
One-click install
npx skills add https://github.com/rudironsoni/dotnet-agent-harness --skill dotnet-csharp-coding-standards
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: dotnet-csharp-coding-standards
Source: https://github.com/rudironsoni/dotnet-agent-harness/tree/main/.rulesync/skills/dotnet-csharp-coding-standards
Command: npx skills add https://github.com/rudironsoni/dotnet-agent-harness --skill dotnet-csharp-coding-standards

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill provides a comprehensive set of C# coding conventions and best practices to ensure code consistency, readability, and maintainability across .NET projects.

Core Features & Use Cases

  • Naming Conventions: Enforces consistent naming for namespaces, classes, methods, properties, etc.
  • Code Style: Defines rules for braces, expression bodies, var usage, and null handling.
  • File Organization: Guides on structuring files and using file-scoped namespaces.
  • Use Case: When generating new C# code or reviewing existing code, this Skill ensures adherence to established standards, making the codebase easier to understand and manage for all developers.

Quick Start

Apply the dotnet-csharp-coding-standards skill to ensure all generated C# code follows established naming and style conventions.

Frequently Asked Questions about dotnet-csharp-coding-standards

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
What are the C# coding standards for .NET projects?

C# coding standards for .NET projects establish baseline conventions for naming, file layout, and style rules to ensure code consistency, readability, and maintainability. They enforce Microsoft Framework Design Guidelines for namespaces, classes, and methods.

How do I enforce C# naming conventions in my codebase?

You can enforce C# naming conventions by applying established rules that guide the naming of namespaces, classes, methods, properties, and async operations. This ensures adherence to Microsoft Framework Design Guidelines across the team.

What is the best way to organize C# files and using directives?

The best way to organize C# files is to follow conventions for file layout, using directives, and file-scoped namespaces. Structuring files this way maintains consistency and makes the codebase easier to manage and understand.

How should I handle var usage and braces in C# code style?

C# code style rules define preferences for using var, braces, expression-bodied members, and null handling. Applying these specific style rules ensures that generated and reviewed code remains consistent and readable.

Can I use these dotnet coding conventions for async operations?

Yes, these dotnet coding conventions explicitly include guidance for async operations alongside rules for classes, methods, and properties. This ensures consistent style and naming practices are applied to asynchronous code.