Compare Protobuf text messages

Compare two messages in the Protocol Buffers text format: two debug prints from your logs, a test's expected and actual output, or two versions of a .txtpb config file.

One-line output, made comparable

A message printed on one line, as ShortDebugString() does, is impossible to compare by eye. Format both sides to lay them out field by field, and the changed fields stand out.

Field order

Turn on Sort keys to order fields by name on both sides, so fields printed in a different order are not reported as changes. Repeated fields keep their order.

Values kept exactly

64-bit integers and escapes are compared exactly as written, so no digit is lost on the way.

Find each change

Changed lines and words are highlighted, long unchanged stretches are folded, and the arrows jump from one change to the next. Both sides stay editable as the highlights follow, and Swap exchanges them.

Private: nothing is uploaded

Formatting, checking and comparing all happen in your browser. Your documents are saved in the browser's own storage on this computer, not on a server, so they never leave your device.

With your permission, we count anonymous visits (which pages and tools are used), never what you type. See Privacy.

Questions

How do I compare expected and actual test output?

Paste the expected message on the left and the actual one on the right, Format both, and turn on Sort keys if the field order may differ.

Do I need the .proto file?

No. Both sides are read with the grammar of the text format, not a schema, so any two messages can be compared without their .proto definition.

Is my data uploaded anywhere?

Your documents aren't: everything runs in your browser, and they are saved on your computer, in the browser's storage for this site. With your permission we count anonymous visits, never their content.

More tools