Free β’ Open Source β’ Privacy-First
Live Demo β’ Documentation β’ Report Bug β’ Request Feature
DevCompiler is a free, open-source collaborative code editor designed for technical interviews, pair programming, and live coding sessions. Built with Clean Architecture principles and modern technologies, it provides real-time code synchronization, instant C# compilation, and seamless collaboration.
- β No Sign-Up Required - Jump straight into coding
- β 100% Free Forever - No premium tiers, no hidden costs
- β Privacy-First - No tracking, no analytics, no data collection
- β Real-time Collaboration - See code changes instantly
- β Built-in Compiler - Execute C# code directly in browser
- β Self-Hostable - MIT licensed, deploy anywhere
| Feature | Description |
|---|---|
| Real-time Sync | Multiple users can edit code simultaneously with zero latency |
| Monaco Editor | VS Code-powered editor with syntax highlighting and IntelliSense |
| C# Compilation | Compile and execute C# code using Roslyn compiler (sandboxed) |
| Live Chat | Built-in chat for communication during coding sessions |
| Room Management | Create, join, and manage collaborative coding rooms |
| Share Links | Simple room sharing via URL - no invitations needed |
- Sandboxed Execution - Blocked dangerous namespaces (IO, Net, Reflection)
- Code Length Limits - Maximum 10,000 characters per submission
- Execution Timeout - 5-second timeout for code execution
- JWT Authentication - Secure token-based authentication
- No Persistent Storage - Code is never permanently stored on servers
DevCompiler follows Clean Architecture (Onion Architecture) principles for maintainability, testability, and scalability.
graph TD
subgraph Client [Frontend - Angular]
UI[Monaco Editor]
SignalR_Client[SignalR Client]
end
subgraph API [Presentation Layer - .NET API]
Controllers
Hubs[SignalR Hubs]
end
subgraph App [Application Layer]
Services
DTOs
end
subgraph Domain [Domain Layer]
Entities
Logic[Business Logic]
end
subgraph Infra [Infrastructure Layer]
EF[EF Core]
Roslyn[Roslyn Compiler]
end
UI --> SignalR_Client
SignalR_Client <-->|WebSocket| Hubs
Controllers --> Services
Hubs --> Services
Services --> Logic
Services --> EF
Services --> Roslyn
style Client fill:#dd0031,stroke:#333,stroke-width:2px,color:#fff
style API fill:#512bd4,stroke:#333,stroke-width:2px,color:#fff
style Infra fill:#178cff,stroke:#333,stroke-width:2px,color:#fff
| Technology | Purpose | Version |
|---|---|---|
| .NET | Backend framework | 8.0 |
| ASP.NET Core | Web API | 8.0 |
| Entity Framework Core | ORM | 8.0 |
| SignalR | Real-time communication | 8.0 |
| Roslyn | C# compiler | Latest |
| PostgreSQL | Database | 16 |
| JWT | Authentication | - |
| Technology | Purpose | Version |
|---|---|---|
| Angular | Frontend framework | 18 |
| TypeScript | Language | 5.x |
| Monaco Editor | Code editor | Latest |
| RxJS | Reactive programming | 7.x |
| SignalR Client | WebSocket client | Latest |
- Docker - Containerization
- Docker Compose - Multi-container orchestration
- GitHub Actions - CI/CD (optional)
# Clone repository
git clone https://github.com/patmat511/DevCompiler.git
cd devcompiler
# Start services
docker-compose up -d
# Frontend will be available at: http://localhost:4200
# Backend API at: http://localhost:50001. Clone and restore:
git clone https://github.com/patmat511/DevCompiler.git
cd devcompiler
dotnet restore2. Setup MSSQL:
docker run -e "ACCEPT_EULA=Y" \
-e "SA_PASSWORD=testpassword" \
-p 1433:1433 \
--name devcompiler-sql \
-d mcr.microsoft.com/mssql/server:2022-latest3. Update connection string in appsettings.json:
{
"ConnectionStrings": {
"DefaultConnection": "Server=localhost,1433;Database=devcompiler;User Id=sa;Password=testpassword;TrustServerCertificate=True;"
}
}4. Run migrations:
cd src/DevCompiler.API
dotnet ef database update5. Start backend:
dotnet run6. Start frontend (new terminal):
cd devcompiler.client
npm install
npm start7. Open browser:
http://localhost:4200
- Navigate to
http://localhost:4200 - Enter your nickname
- Click "Create New Room"
- Share the room URL with collaborators
- Open the shared room URL
- Enter your nickname
- Start coding!
- Write C# code in the editor
- Click "Compile & Run"
- View output in the results panel
- All participants see code changes instantly
- Live cursor positions shown
- Built-in chat for communication
Generate JWT token with nickname.
Request:
{
"nickname": "john_dev"
}Response:
{
"token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...",
"userId": "550e8400-e29b-41d4-a716-446655440000",
"nickname": "john_dev"
}Get all active rooms.
Response:
[
{
"id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"name": "Algorithm Practice",
"participantCount": 3,
"createdAt": "2024-12-07T10:30:00Z"
}
]Create a new room.
Request:
{
"name": "Interview Session"
}Get room details by ID.
Compile and execute C# code.
Request:
{
"code": "Console.WriteLine(\"Hello World!\");"
}Response:
{
"success": true,
"output": "Hello World!\n",
"errors": [],
"warnings": [],
"executionTime": "00:00:00.1234567"
}Endpoint: /hub
Methods:
JoinRoom(roomId)- Join a roomLeaveRoom(roomId)- Leave a roomSendMessage(roomId, message)- Send chat messageUpdateCode(roomId, code)- Sync code changes
# Run all tests
dotnet test
# Run with coverage
dotnet test /p:CollectCoverage=true