npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

firebase-jwt-token

v1.0.11

Published

Quickly get a Firebase Auth token using Email/Password

Readme

firebase-jwt-token

Build Publish

A CLI utility to generate Firebase Auth JWT token for a given Email/Password. This is useful if you want to get a JWT token to use during development.


Installation

From npm registry:

npm install -g firebase-jwt-token

Usage

➜  ~$ firebase-jwt-token --help
Options:
  --help          Show help                                            [boolean]
  --version       Show version number                                  [boolean]
  --decode, -d    Return decoded token as json instead of JWT Token    [boolean]
  --email, -e     Email to log in with. Optionally use environment
                  variable FJT_EMAIL                         [string] [required]
  --password, -p  Password to log in with. Optionally use environment
                  variable FJT_PASSWORD                      [string] [required]
  --key, -k       Firebase Project Web API Key (can be found under project
                  settings). Optionally use environment variable FJT_KEY
                                                             [string] [required]

Examples

Create a user in Firebase Auth using Email/Password method. To get the JWT ID Token, run:

➜  ~$ firebase-jwt-token --email [email protected] --password qwe123 --key AIzaSyAlLdsqBwCNzkPFIijGuZFqBNUnwTw5uz8
eyJhbGciOiJSUzI1NiIsImtpZCI6Ijg4ODQ4YjVhZmYyZDUyMDEzMzFhNTQ3ZDE5MDZlNWFhZGY2NTEzYzgiLCJ0eXAiOiJKV1QifQ.eyJpc3MiOiJodHRwczovL3NlY3VyZXRva2VuLmdvb2dsZS5jb20vZmlyLWp3dC10b2tlbiIsImF1ZCI6ImZpci1qd3QtdG9rZW4iLCJhdXRoX3RpbWUiOjE1ODg1MjQ5NzksInVzZXJfaWQiOiJjaE9jNXZJUmU4U0pOdGRTRXVUSlRNVDdCcjIzIiwic3ViIjoiY2hPYzV2SVJlOFNKTnRkU0V1VEpUTVQ3QnIyMyIsImlhdCI6MTU4ODUyNDk3OSwiZXhwIjoxNTg4NTI4NTc5LCJlbWFpbCI6InNvbWVlbWFpbEBqb25hdGhhbnN1ZGhha2FyLmNvbSIsImVtYWlsX3ZlcmlmaWVkIjpmYWxzZSwiZmlyZWJhc2UiOnsiaWRlbnRpdGllcyI6eyJlbWFpbCI6WyJzb21lZW1haWxAam9uYXRoYW5zdWRoYWthci5jb20iXX0sInNpZ25faW5fcHJvdmlkZXIiOiJwYXNzd29yZCJ9fQ.jMy1IsBKUiBSsfku-3ftCHf_C0pJU6hkbppLU0RdkNbC-fIM_DhQXzCZ-_PGRVTdxgaqHAqfGXMgWTAoAlSllN0g7E5uv5zop8x_fNvU06ZFpR7nE5hSroWAsEVAdcu_OeM27hbZxpzJuADEs0eC-qjJRUkUCDDiqyuGYwJjIMPCecuqVGXmNyVAIuIi_OltcEx8DEgtQCQnj-0pT1R3y5EAECejZDGO5qC4eOcuUvNP1SQ9hVvwjy4VD6udEE_qzZTHu-aYE9htiNFQeTiALEFpbGHqvKM1q8SEOAZoAuMiOMw76SYot7Plch_AkKZbcn_aqkYFktes7RwX6Oqpzg

To decode the token, add the -d argument:

➜  ~$ firebase-jwt-token --email [email protected] --password qwe123 --key AIzaSyAlLdsqBwCNzkPFIijGuZFqBNUnwTw5uz8 -d
{"iss":"https://securetoken.google.com/fir-jwt-token","aud":"fir-jwt-token","auth_time":1588525065,"user_id":"chOc5vIRe8SJNtdSEuTJTMT7Br23","sub":"chOc5vIRe8SJNtdSEuTJTMT7Br23","iat":1588525065,"exp":1588528665,"email":"[email protected]","email_verified":false,"firebase":{"identities":{"email":["[email protected]"]},"sign_in_provider":"password"}}

You can also set the arguments in environment variables:

➜  ~$ export FJT_KEY=AIzaSyAlLdsqBwCNzkPFIijGuZFqBNUnwTw5uz8
➜  ~$ export FJT_PASSWORD=qwe123
➜  ~$ export [email protected]
➜  ~$ firebase-jwt-token
eyJhbGciOiJSUzI1NiIsImtpZCI6Ijg4ODQ4YjVhZmYyZDUyMDEzMzFhNTQ3ZDE5MDZlNWFhZGY2NTEzYzgiLCJ0eXAiOiJKV1QifQ.eyJpc3MiOiJodHRwczovL3NlY3VyZXRva2VuLmdvb2dsZS5jb20vZmlyLWp3dC10b2tlbiIsImF1ZCI6ImZpci1qd3QtdG9rZW4iLCJhdXRoX3RpbWUiOjE1ODg1MjUyNjMsInVzZXJfaWQiOiJjaE9jNXZJUmU4U0pOdGRTRXVUSlRNVDdCcjIzIiwic3ViIjoiY2hPYzV2SVJlOFNKTnRkU0V1VEpUTVQ3QnIyMyIsImlhdCI6MTU4ODUyNTI2MywiZXhwIjoxNTg4NTI4ODYzLCJlbWFpbCI6InNvbWVlbWFpbEBqb25hdGhhbnN1ZGhha2FyLmNvbSIsImVtYWlsX3ZlcmlmaWVkIjpmYWxzZSwiZmlyZWJhc2UiOnsiaWRlbnRpdGllcyI6eyJlbWFpbCI6WyJzb21lZW1haWxAam9uYXRoYW5zdWRoYWthci5jb20iXX0sInNpZ25faW5fcHJvdmlkZXIiOiJwYXNzd29yZCJ9fQ.nFQS-7cLeFmBb7g9WcJOw6bT5dMnN0vATiobXqg0qXaj3J2BIf5GhGv9yzPSGMXJ27Lw3B_iQ1B_Zkc0UesQLIs_yBtY-TFh5wGNAM8Lm_btB9A4PJUsgZJmWxSFoyO9IZv3hjxali-c2CoJP0YPp51RBvSsagwrdCFu7lvN05g_2ckFr2ewy-rOhRGNI01yqs_Yyh__psF-SOR8A2CqzXDllElJtA78e7mgM4bMdkP9-YA8l9vhk4ErLa_6MJbf1Ln7cm_KYJ1WR9S794AkmkFSz5vdc8cnQqcDKGkccJ1c6sSEYkzPFHuQfIlTK1MIZSAnEW_sVrERDjyRTwYtlw

API Key Location

The API Key can be found under the Firebase project's general settings:

API Key Screenshot


Project Location

Please feel free to create Issues/PRs: Git NPM Registry GitHub Registry