JWT Encoder

Build a signed JSON Web Token with the HS256 algorithm. Edit the header and payload as JSON, enter a shared secret, then sign. For local testing and learning—not a substitute for a hardened identity provider.

JWT (HS256)

Header and payload must be JSON objects. Signing uses Web Crypto in your browser.

How it works

The header and payload are JSON-stringified, Base64url-encoded, and concatenated with a dot. The signature is HMAC-SHA256 of that string, Base64url-encoded. Only HS256 is supported on this page.

Quick tips

  • Validate one known sample first, then batch-process the rest.
  • Keep timezone and locale assumptions explicit in your test input.
  • Copy both source and output when sharing debugging context.

Use this tool for

  • Generating sample JWTs for API mocks or unit tests.
  • Verifying what claims fit before wiring an auth server.
  • Learning how compact JWS serialization works.

Common questions

Does JWT Encoder cover every edge case for JWT?

Confirm the field units (px, degrees, charset) match what you intend; mixed bases are the usual surprise on this kind of tool.

Is anything I type sent to NexUtility servers?

Different rounding or parsing rules can shift edge-case output—sanity-check with a tiny hand example when precision matters.