Go to Sign up
Note: Your files never leave your device. We don't upload, transfer, or store your data.
|
|
|
|
|---|---|---|
|
|
|
The Markdown To Protocol Buffers Converter on A.Tools transforms Markdown pipe-delimited tables into .proto definitions — valid Protocol Buffers schema code you can use in gRPC services, data serialization pipelines, and cross-language API contracts. All processing runs in your browser. No data leaves your device.
API schemas and data models are often sketched as Markdown tables in design documents, wikis, and RFCs. Protocol Buffers requires a formal .proto file with message definitions, typed fields, and field numbers. This tool bridges that gap.
Click Enter Data to paste a Markdown table into the input area, or click Choose File to drag and drop a .md file. Press Sample to load example data.
Once parsed, an interactive spreadsheet appears. Use the toolbar to:
Add or delete rows and columns
Transpose the table (swap rows and columns)
Remove duplicate rows
Delete empty rows and columns
Change text case (UPPERCASE, lowercase, Capitalize)
Find and replace values — supports case-sensitive search and regex
Toggle First Row as Header to define field names
Right-click any cell for context-menu operations.
In the Properties panel:
| Setting | Default | Description |
|---|---|---|
| Syntax | proto3 | Protocol Buffers syntax version (proto2 or proto3) |
| Package Name | my_package | The package declaration in the .proto file |
| Message Name | MyMessage | The message type name for the generated definition |
| Field Type Detection | Auto Detect | Analyze cell values to infer types, or force all fields to string |
| Indent Size | 2 spaces | Indentation inside the message block |
Click Convert to generate .proto code. Use Copy to Clipboard or Download File to save as a .proto file.
Two input modes: Paste Markdown directly or upload a .md file via drag-and-drop
Full table editor: Edit, transpose, deduplicate, find-and-replace before converting
Proto2 and proto3 support: Choose the syntax version that matches your project
Custom package and message names: Configure the .proto file structure
Smart type detection: Automatically infer int32, double, bool from cell values
Configurable indentation: 2, 4, or 8 spaces
Client-side processing: Files never leave the browser — zero data upload
Undo/Redo: Full edit history with revert support
Context menu: Right-click for quick row/column/cell operations
Header toggle: Treat the first row as field names or regular data
Validation indicator: Real-time feedback on input validity
Given this Markdown input:
| field_name | type | value |
|------------|----------|-------|
| id | int32 | 1 |
| name | string | 2 |
| email | string | 3 |
| active | bool | 4 |
| score | double | 5 |
The tool generates:
syntax = "proto3";
package my_package;
MyMessage {
int32 id = 1;
string name = 2;
string email = 3;
bool active = 4;
double score = 5;
}
The tool inspects cell values in the data rows and maps them to protobuf scalar types:
| Detected Pattern | Protobuf Type |
|---|---|
Integers (e.g., 42, -7) | int32 |
Decimals (e.g., 3.14, -0.5) | double |
true / false | bool |
| Everything else | string |
All fields are generated as string regardless of content:
syntax = "proto3";
package my_package;
MyMessage {
string field_name = 1;
string type = 2;
string value = 3;
}
Protocol Buffers (protobuf) is Google's language-neutral, platform-neutral extensible mechanism for serializing structured data. You define how you want your data structured in .proto files, then use the protocol compiler (protoc) to generate source code in languages including Java, Python, Go, C++, C#, Ruby, and JavaScript.
syntax: Declares the proto version. proto3 is the current default.
package: Prevents naming conflicts between different projects.
message: Defines a structured data type with typed fields.
Field numbers: Each field is assigned a unique number (1–536870911) used in the binary encoding. These numbers must never change once the message is in use.
| Protobuf Type | Go | Java | Python | C++ |
|---|---|---|---|---|
double | float64 | double | float | double |
float | float32 | float | float | float |
int32 | int32 | int | int | int32 |
int64 | int64 | long | int/long | int64 |
uint32 | uint32 | int | int/long | uint32 |
uint64 | uint64 | long | int/long | uint64 |
sint32 | int32 | int | int | int32 |
sint64 | int64 | long | int/long | int64 |
fixed32 | uint32 | int | int | uint32 |
fixed64 | uint64 | long | int/long | uint64 |
sfixed32 | int32 | int | int | int32 |
sfixed64 | int64 | long | int/long | int64 |
bool | bool | boolean | bool | bool |
string | string | String | str/unicode | string |
bytes | []byte | ByteString | str | string |
Official reference: Protocol Buffers Language Guide (proto3)
| Feature | proto2 | proto3 |
|---|---|---|
| Syntax declaration | syntax = "proto2"; | syntax = "proto3"; |
| Default syntax (if omitted) | proto2 | — (must declare) |
| Required fields | Supported (required) | Not supported |
| Optional fields | Supported (optional) | All fields are implicitly optional |
| Default values | Explicit default keyword | Zero-value defaults (0, "", false) |
| Field presence tracking | Has hasXxx() methods | Only tracks non-default values |
| Enum first value | Can be any value | Must be 0 |
| Extensions | Supported | Not supported (use Any) |
| JSON mapping | Not built-in | Native support |
| Recommended for | Legacy systems, strict validation | New projects, gRPC |
Recommendation: Use proto3 for all new projects. It is simpler, has native JSON support, and is the default for gRPC. Use proto2 only when maintaining existing systems that depend on required fields or extensions.
The tool examines the data rows (not the header) to infer each column's protobuf type:
| name | age | score | enrolled |
|-------|-----|-------|----------|
| Alice | 30 | 95.5 | true |
| Bob | 25 | 88.0 | false |
Generates:
MyMessage {
string name = 1;
int32 age = 2;
double score = 3;
bool enrolled = 4;
}
Every column is typed as string, regardless of content:
MyMessage {
string name = 1;
string age = 2;
string score = 3;
string enrolled = 4;
}
Use "All String" when your Markdown table contains only field names and descriptions (like a schema specification), not actual data values for type inference.
| Scenario | Why Convert |
|---|---|
| gRPC service design | Convert API design tables from RFCs into .proto files |
| API contracts | Transform shared specification tables into formal schema definitions |
| Microservices | Generate message types from data models documented in wikis |
| Data serialization | Move documented data structures into protobuf for efficient wire format |
| Code generation | Feed .proto files into protoc to generate stubs in 10+ languages |
| Database schema migration | Convert tabular schema docs into protobuf messages for NoSQL backends |
| Team handoffs | Bridge the gap between product specs (Markdown) and engineering (protobuf) |
| Prototyping | Quickly generate .proto drafts from planning spreadsheets |
A product specification written as a Markdown table:
| field | type | number |
|----------|--------|--------|
| user_id | int32 | 1 |
| username | string | 2 |
| email | string | 3 |
Converts to:
syntax = "proto3";
package user_service;
User {
int32 user_id = 1;
string username = 2;
string email = 3;
}
service UserService {
rpc GetUser (User) returns (User);
}
No. All file parsing and conversion runs in your browser using JavaScript. Your data stays on your device. A.Tools never receives, stores, or transmits your file contents.
The tool supports standard pipe-delimited Markdown tables following the CommonMark specification, including tables with or without leading/trailing pipes and alignment indicators.
The tool generates a complete .proto file with a syntax declaration, package statement, and a message definition containing typed fields with unique field numbers. See the "What the Output Looks Like" section above for examples.
Proto3 is the recommended syntax for new projects. It is simpler — no required fields, no extensions, native JSON mapping, and all fields are implicitly optional. Proto2 supports required/optional keywords and explicit default values. Use proto2 only for legacy systems.
In Auto Detect mode, the tool examines data values in each column and maps integers to int32, decimals to double, true/false to bool, and everything else to string. In All String mode, all fields are typed as string regardless of content.
Yes. Enter any valid Protocol Buffers identifier in the Package Name and Message Name fields. Names should start with a letter and contain only letters, numbers, and underscores.
Yes. After parsing, the full table editor lets you modify cells, add or remove rows and columns, transpose, deduplicate, change text case, and find-and-replace values.
Yes. Field numbers are assigned sequentially starting from 1, based on column order. Field numbers are critical in protobuf — once deployed, they must never change.
Processing is client-side, so the limit depends on your browser's memory. Tables with tens of thousands of rows work reliably on modern browsers.