Introducing new capabilities for teams, third-party authentication and real-time database streaming!
Fauna logo
Log InSign Up
Fauna logo
Sign Up
© 2021 Fauna, Inc. All Rights Reserved.
<- Back

The Fauna Extension for Visual Studio Code

Lewis King|Feb 26th, 2020|



FaunaDB extension for VS Code allows users to browse their FaunaDB databases, indexes, collections, documents, and functions from right inside of the VS Code sidebar. Users are also able to edit their FaunaDB documents from within VS Code and run Fauna Query Language queries within VS Code against their FaunaDB database.

What is VS Code?

VS (Visual Studio) Code is a code editor redefined and optimized for building and debugging modern web and cloud applications. VS Code is free and developed by Microsoft for Windows, Linux, and macOS. It includes support for debugging, built-in commands for Git, syntax highlighting, intelligent code completion, snippets, code refactoring, and customization via extensions.

Getting Started

Be sure to install VS Code, install the FaunaDB extension for VS Code, and create a FaunaDB account.

To get started using the FaunaDB VS Code extension, you'll need to set your secret key in order to access database information. Keys can be created in the FaunaDB Dashboard or via the Shell CLI.

Important: Generate an "admin" key, not a "server" key.

Once you have the secret key, configure the FaunaDB extension for VS code by going to: Code > Preferences > Settings > Extensions > FaunaDB.

Then paste the secret key into the Secret Key field, and reload VS Code.

faunadb.secretKey: Your database secret.

Warning: Be careful! To avoid exposing this secret, do not commit it to your local .vscode configuration.


  • FaunaDB: Create Query
  • FaunaDB: Run Query

Browse database

With this extension, you can browse the databases, indexes, collections, documents, and functions associated with your FaunaDB database right inside of the VS Code sidebar.

Run queries

In addition to browsing your data, this extension also allows you to run FQL queries against your FaunaDB database.

Benefits for users of VS Code and FaunaDB

Using the FaunaDB extension for VS Code, users can access FaunaDB directly from the editor, a faster alternative to visiting the FaunaDB Dashboard in a web browser.

VS Code users have a new NoSQL database option with all of the unique benefits that FaunaDB offers, including 100% ACID transactions. They can use FaunaDB as a stateful component of their apps with ease and avail of its generous free tier. Databases are available for use instantly: no additional provisioning is necessary within FaunaDB, making for seamless serverless development experience. Globally distributed data ensures that data is close to where your users are, thus enabling snappy user experience for your apps

Finally, documents created via the extension can be managed via FaunaDB Dashboard as well as FaunaDB Shell and VS Code extension for hassle-free use.


With this extension, users are able to browse their FaunaDB databases, indexes, collections, documents, and functions from right inside of the VS Code sidebar.

Please visit the FaunaDB documentation to learn more. And please let us know what you think so that we can incorporate your feedback into a future release.

What other integrations would you like to see implemented in FaunaDB? Please reach out to me on Twitter or our Community Slack and describe any other features that would make FaunaDB and Netlify an obvious choice for your next project.

If you enjoyed our blog, and want to work on systems and challenges related to globally distributed systems, serverless databases, GraphQL, and Jamstack, Fauna is hiring!

Share this post


Subscribe to Fauna blogs & newsletter

Get latest blog posts, development tips & tricks, and latest learning material delivered right to your inbox.

<- Back