jwtd

webcodr·WebCodr.jwtd

Decode and pretty-print JSON Web Tokens with syntax highlighting

jwtd is a command-line tool that decodes and pretty-prints JSON Web Tokens (JWT) and JSON Web Encryption (JWE) tokens with syntax-highlighted JSON output. It can verify JWS signatures and decrypt JWEs when given a key via the --key flag or the JWTD_KEY environment variable.

winget install --id WebCodr.jwtd --exact --source winget

Latest 5.9.0·November 27, 2026

Release Notes

Extraction and signed-then-encrypted tokens

This release adds single-value extraction for shell pipelines and end-to-end checking of signed-then-encrypted tokens such as encrypted OIDC ID tokens.

What's new

Section and claim extraction. --header, --payload, and --claim <name> print one part of a token, so sub=$(jwtd -k issuer.pem --claim sub "$TOKEN") works without jq. String claims print bare, other values as compact JSON, and --json JSON-encodes every value. Every requested check still runs, and if one fails, nothing is printed to stdout:the verdict goes to stderr and the exit status is nonzero, so a script never receives a value that failed a check it asked for.

A separate verification key. --verify-key (or JWTD_VERIFY_KEY) verifies JWS signatures at any depth, while --key keeps decrypting every JWE layer. A token signed by an issuer and encrypted to you can now be checked in one command:

jwtd --key private-key.pem --verify-key issuer-public-key.pem "$TOKEN"

An explicit --verify-key is never skipped:if it cannot be used on a nested signature, or the token holds no signature at all, the command fails. An empty --verify-key is rejected.

Claim validation and --json reach inside a JWE. Claim flags now validate the innermost claims set:the claims of a token nested in the JWE, or a decrypted JSON payload. --json output for a JWE gains nested (the inner token, including its signatureValid) and claimsValid.

Behaviour changes

• Claim flags on a JWE are no longer skipped. jwtd --verify-claims <jwe> used to print a note and exit 0. It now validates the innermost claims, and claims it cannot reach — no --key to decrypt, an undecryptable nested JWE, or a payload that is not a JSON object — are reported as Claims:INVALID with a nonzero exit. • --json now checks the inner signature of a nested token. With only --key, the decryption key is offered to the inner signature, as the human output has always done. For an encrypted ID token signed with the issuer's own key, that reports signatureValid:false and exits nonzero where --json used to exit 0 without checking the inner signature at all. Pass --verify-key with the issuer's key; a stderr note says so whenever this happens. • A top-level JWE that fails to decrypt is now reported before its protected header is printed.

What's Changed

• docs(site):document v5.8.0 CLI ergonomics features by @bsg62 in https://github.com/webcodr/jwtd/pull/36 • docs(site):tighten claim, alg, and decode copy by @bsg62 in https://github.com/webcodr/jwtd/pull/37 • feat:add --header, --payload, and --claim extraction by @bsg62 in https://github.com/webcodr/jwtd/pull/38 • feat:add --verify-key and validate nested claims by @bsg62 in https://github.com/webcodr/jwtd/pull/39 • docs(site):document extraction and verify-key features by @bsg62 in https://github.com/webcodr/jwtd/pull/40

Full Changelog:https://github.com/webcodr/jwtd/compare/v5.8.0...v5.9.0

Installer type: zip

x64—87202AAE3890B015D6608115237944630392F512FEEED5310DEDCA643DCBD4CD
arm64—24E076D916630DC29DC913C3237AB5D7991DDF6CEEE57F7827823B4EE1F1E292

Details

Homepage
https://github.com/webcodr/jwtd
License
MIT
Publisher
webcodr
Support
https://github.com/webcodr/jwtd/issues
Copyright
Copyright (c) David Henning
Moniker
jwtd

Tags

clicommand-linecommand-line-tooljwejwtjwt-decodejwt-decoderjwt-token

Older versions (5)

5.7.1
x64—FAA76E5AF0AFE6A7DF38DB2FD967B1EF46AD460106C5E0627F27CA89B75AC74A
arm64—DE44CAB1393767605CC1742966DD2DC7E4A00970156D2CDAD0F0CE9C0AF8CCBE
5.7.0
x64—4C8FD855A613E90CC601D904B30A9EF8CA75130A620D86855CEF4595EEBCAF4B
arm64—16D8A31007DE27244E197C95FBF7EF2261740CD2066D4B2BA815DD21CDA7F700
5.6.0
x64—EEB79B01FE7275F94A4C5205708077612F81D522EEA76085846A185842260971
arm64—5738DB348B94A5412ABB73DBD962266F32D4E5B5F986F7517838C01A3BB41466
5.3.0
x64—F47B0660C12B6078BAB4EBAA53856744EA15B84951204F7748D1BCCFCAD32509
arm64—3E767347AEFC3AC349FFFAF81825F7AB3C95BE2EBB22679E6EA878B2F94DBD98
5.2.0
x64—1FE8F3AA854CBE64C7ECEDFCF2B5583C6E3B6CC7BC059767EED1BFE14A8EDE59
arm64—3920AD0534DAD2033AD1BCBD03BC9BAEC1491A1BBA6DF6764439D10CAC726489