Back to Articles

fx: The Terminal JSON Viewer That Makes jq Look Verbose

[ View on GitHub ]

fx: The Terminal JSON Viewer That Makes jq Look Verbose

Hook

With over 20,000 GitHub stars, fx has become one of the most popular JSON tools in the Go ecosystem—a terminal JSON viewer and processor that offers an alternative approach to working with JSON in the command line.

Context

JSON has become ubiquitous in modern development. APIs return it, configs use it, logs output it. But reading JSON in the terminal can be challenging. Tools like cat dump unformatted text, while more specialized tools require learning new syntax. GUI tools work for exploration but break terminal-centric workflows and can’t easily be piped or scripted.

Anton Medvedev built fx as a terminal JSON viewer and processor. The tool appears designed to provide both interactive exploration and scriptable processing capabilities, positioning itself as an option for developers who work with JSON data regularly in terminal environments.

Technical Insight

Interactive Mode

Raw JSON

Parsed Data

Current View

Display

Navigation/Commands

Filter Expression

Transformed Data

JSON Input

stdin/file

JSON Parser

Internal Data Model

Tree Structure

Terminal UI

Renderer

Keyboard Input

Handler

Expression Evaluator

JavaScript-like

Formatted Output

stdout

System architecture — auto-generated

fx is a single Go binary that processes JSON from stdin or files. The tool provides an interactive terminal interface for navigating JSON structures, though the exact implementation details are not extensively documented in the project README.

Based on the repository, fx appears to support both interactive and non-interactive modes:

# Interactive mode - pipe JSON in
curl https://api.github.com/repos/antonmedv/fx | fx

# Non-interactive mode for scripting
curl https://api.github.com/repos/antonmedv/fx | fx <expression>

The tool is written in Go and presents itself as a JSON viewer and processor. The specific feature set, including whether it uses JavaScript for expressions (as the ‘f(x)’ name might suggest), what keyboard shortcuts it supports, and how it handles large files, would need to be verified through the full documentation at fx.wtf rather than the README alone.

The project appears focused specifically on JSON processing. As a Go binary, it likely offers fast startup times and cross-platform compatibility, making it suitable for inclusion in developer toolchains alongside other command-line utilities.

Gotcha

The README provides minimal detail about fx’s capabilities and limitations, directing users to fx.wtf for full documentation. This makes it difficult to assess the tool’s boundaries without additional research. Key questions remain unanswered in the repository documentation: What expression syntax does fx actually support? What are its performance characteristics with large files? What features does the interactive mode provide?

As a focused tool described simply as a ‘Terminal JSON viewer & processor,’ fx likely has a specific scope. Without detailed documentation in the README, developers should consult the full documentation before relying on fx for production workflows or complex data processing tasks. The tool may be optimized for particular use cases while not attempting to be a universal JSON processor.

The interactive terminal interface, while likely useful for exploration, may not be suitable for all environments—headless servers, CI/CD pipelines, or situations without proper TTY allocation might require non-interactive usage patterns.

Verdict

Consider fx if you regularly work with JSON in terminal environments and want a dedicated viewer/processor tool. With over 20,000 GitHub stars, it has clearly resonated with developers, suggesting it solves a real problem in a way that users appreciate. The tool appears designed for the common case of exploring and processing JSON data from the command line.

The limited README means you should review the full documentation at fx.wtf to understand whether fx’s feature set matches your workflow. Being written in Go suggests good performance and easy installation as a single binary. The project is actively maintained by a developer who has created other well-regarded terminal tools (walk, howto, countdown), indicating sustained attention to terminal-based developer experience.

Skip fx if you need extensive documentation directly in the repository, require guaranteed support for specific features before installation, or have already invested heavily in alternative tools. The sparse README is a deliberate choice that prioritizes a clean repository over embedded documentation, but it does mean more research is required upfront to evaluate fit for your specific use case.

// ADD TO YOUR README
[![Featured on Starlog](https://starlog.is/api/badge/developer-tools/antonmedv-fx.svg)](https://starlog.is/api/badge-click/developer-tools/antonmedv-fx)