WHY GARTNER’S “CONTEXT MESH” CHANGES EVERYTHING AI CONNECTIVITY: THE ROAD AHEAD DON’T MISS API + AI SUMMIT 2026 SEPT 30 – OCT 1
  • Why Kong
    • Explore the unified API Platform
        • BUILD APIs
        • Kong Insomnia
        • API Design
        • API Mocking
        • API Testing and Debugging
        • MCP Client
        • RUN APIs
        • API Gateway
        • Context Mesh
        • AI Gateway
        • Event Gateway
        • Kubernetes Operator
        • Service Mesh
        • Ingress Controller
        • Runtime Management
        • DISCOVER APIs
        • Developer Portal
        • Service Catalog
        • MCP Registry
        • GOVERN APIs
        • Metering and Billing
        • APIOps and Automation
        • API Observability
        • Why Kong?
      • CLOUD
      • Cloud API Gateways
      • Need a self-hosted or hybrid option?
      • COMPARE
      • Considering AI Gateway alternatives?
      • Kong vs. Postman
      • Kong vs. MuleSoft
      • Kong vs. Apigee
      • Kong vs. IBM
      • GET STARTED
      • Sign Up for Kong Konnect
      • Documentation
      • FOR PLATFORM TEAMS
      • Developer Platform
      • Kubernetes and Microservices
      • Observability
      • Service Mesh Connectivity
      • Kafka Event Streaming
      • FOR EXECUTIVES
      • AI Connectivity
      • Open Banking
      • Legacy Migration
      • Platform Cost Reduction
      • Kafka Cost Optimization
      • API Monetization
      • AI Monetization
      • AI FinOps
      • FOR AI TEAMS
      • AI Governance
      • AI Security
      • AI Cost Control
      • Agentic Infrastructure
      • MCP Production
      • MCP Traffic Gateway
      • FOR DEVELOPERS
      • Mobile App API Development
      • GenAI App Development
      • API Gateway for Istio
      • Decentralized Load Balancing
      • BY INDUSTRY
      • Financial Services
      • Healthcare
      • Higher Education
      • Insurance
      • Manufacturing
      • Retail
      • Software & Technology
      • Transportation
      • See all Solutions
  • Pricing
      • DOCUMENTATION
      • Kong Konnect
      • Kong Gateway
      • Kong Mesh
      • Kong AI Gateway
      • Kong Event Gateway
      • Kong Insomnia
      • Plugin Hub
      • EXPLORE
      • Blog
      • Learning Center
      • eBooks
      • Reports
      • Demos
      • Customer Stories
      • Videos
      • EVENTS
      • API + AI Summit
      • Webinars
      • User Calls
      • Workshops
      • Meetups
      • See All Events
      • FOR DEVELOPERS
      • Get Started
      • Community
      • Certification
      • Training
      • COMPANY
      • About Us
      • We're Hiring!
      • Press Room
      • Contact Us
      • Kong Partner Program
      • Enterprise Support Portal
      • Documentation
  • Login
  • Book Demo
  • Get Started
Blog
  • AI Gateway
  • AI Security
  • AIOps
  • API Security
  • API Gateway
|
    • API Management
    • API Development
    • API Design
    • Automation
    • Service Mesh
    • Insomnia
    • View All Blogs
  1. Home
  2. Blog
  3. Engineering
  4. 3 Solutions for Avoiding Plain-Text Passwords in Insomnia
Engineering
December 8, 2020
3 min read

3 Solutions for Avoiding Plain-Text Passwords in Insomnia

Kevin Chen

When testing APIs, software engineers often repeat identical values across multiple requests, but who wants to waste time typing the same values every time?

Insomnia's environment variables solve this problem by allowing you to define a value once as an environment variable and reference that value wherever it’s needed. Insomnia also enables you to override certain variables using sub-environments or folder environments. Standard variables are base URLs, authentication tokens and resource IDs, but you can create any variables that help you save time.

Eventually, you'll run into a request that requires some form of authentication. The issue with storing passwords in plain text is that anyone can read them.

The Solutions We Discovered Together

This issue prompted the community to question how to avoid plain-text passwords in the “Manage Environments” section of Insomnia. Thanks to a combination of community contributions and Insomnia features, you can easily avoid this situation through various options:

1. Use Private Environments

The easiest solution is to use private environments. A private environment will never be exported or synced. However, it will still be in plain text, so it doesn't completely solve the issue at hand, but I wanted to point out that it is available.

2. Use ENV Files

My preferred option would be using env files. An Insomnia plugin created by community member Edirin made this possible. Huge thanks to him for creating this Insomnia Plugin – dotenv that makes it tenfold easier to use env files in environments.

To use Edirin's creation:

  1. Open Insomnia preferences. The shortcuts are (Ctrl + ,) or (Cmd + ,) depending on your operating system.
  2. Navigate to the Plugins tab and type in "insomnia-plugin-dotenv" in the search bar.
  3. Click "Install Plugin."

Plain-Text Passwords in Insomnia: Install DotEnv Plugin

The alternative, and perhaps easier, installation method is to visit the plugin hub and click the "Install in Core" button on the top right.

After installing the dotenv plugin:

  1. Navigate back to the "Manage Environment" page.
  2. Create a key-value-pair where the value references the "dotenv" plugin you just installed. The process uses regular JSON, so add your key, and when typing the value, press ctrl + space (or cmd + space) and select the dotenv plugin from the autocomplete dropdown. Then, click on the tag and configure the plugin. Here is an example of what it would look like:

Plain-Text Passwords in Insomnia: Configure Plugin DotEnv

  1. Choose the .env file and which variable name you need to retrieve from it. The live preview below is a nice touch to ensure you see the value assigned to the variable.
  2. Click "Done," and you're good to go!

3. Use ENV Files With Sub Environments

Opender took it one step further by utilizing the Insomnia Plugin – dotenv alongside sub environments.

  1. As seen in this sample environment, you'll want to map each variable against the env file in the base Insomnia environment.
  2. Specify an envFilePath variable in the three sub environments, e.g., .env.local, .env.staging and .env.production.
  3. Most importantly, when consuming the dotenv plugin, reference the envFilePath variable instead of hard-coding it.

Plain-Text Passwords in Insomnia: envfilepath

This is handy for collaboration. The environment variable setup is shared (in the base environment). Still, each collaborator provides the specific keys from a file on their file-system, which is never synced or exported.

Thank You, Insomnia Community!

The results of this collaboration to avoid plain-text passwords in Insomnia demonstrate two things:

  1. The community is incredible.
  2. Insomnia is awesome.

The combination of these two created a fantastic new plugin and excellent use case. I'd like to make one last shout out to Alex for kicking it off in the following GitHub issue. We're all a little better at protecting our plain-text passwords now, thanks to you.

You can explore the other 250+ Insomnia plugins available on the Plugin Hub. There are tons of excellent open source plugins. If you can't find something you need, Insomnia has documentation to help you create your own.

Check out our recent blog post for even more Insomnia tips: Service Design Guidelines with OpenAPI and Kong

InsomniaAPI SecuritySecrets Management

More on this topic

Webinars

Why API-First Starts With Kong Insomnia

Videos

PEXA’s Resilient API Platform on Kong Konnect

See Kong in action

Accelerate deployments, reduce vulnerabilities, and gain real-time visibility. 

Get a Demo
Topics
InsomniaAPI SecuritySecrets Management
Kevin Chen

Recommended posts

Kong Insomnia 11: Elevating API Security and Collaboration

Product ReleasesMarch 18, 2025

We’re excited to announce the general availability of Kong Insomnia 11! This release introduces third-party vault integrations for enhanced security, an all-new Git sync experience for more seamless collaboration, and support for multi-tabs to impro

Adam Jiroun

Evaluating API Testing Tools: Insomnia vs Postman

EnterpriseMarch 26, 2026

Free collaboration with Postman — a myth On March 1st, 2026, Postman discontinued free collaboration for small teams. Now , Git or Cloud-native collaboration requires a Team plan starting at $19 per person per month. That means even a 3-person team

Haley Giuliano

Practical Strategies to Monetize AI APIs in Production

EngineeringMarch 27, 2026

Traditional APIs are, in a word, predictable. You know what you're getting: Compute costs that don't surprise you Traffic patterns that behave themselves Clean, well-defined request and response cycles AI APIs, especially anything that runs on LLMs

Deepanshu Pandey

Connecting Kong and Solace: Building Smarter Event-Driven APIs

EngineeringMarch 20, 2026

Running Kong in front of your Solace Broker adds real benefits: Authentication & Access Control – protect your broker from unauthorized publishers. Validation & Transformation – enforce schemas, sanitize data, and map REST calls into event topics.

Hugo Guerrero

Announcing Kong's Integration with Vault!

NewsMay 28, 2019

Today we’re excited to show how Kong Enterprise customers can utilize our new plugin for HashiCorp Vault for authentication and secrets management. Like the Terraform integration released last year, this new integration with Vault represents ano

Mike Bilodeau

Bringing Identity-Aware Security & Policy Enforcement to Event Streaming

Product ReleasesMarch 25, 2026

The widespread adoption of Kafka and event streaming platforms is evident across several enterprises, where they serve as the backbone of critical operations, ranging from financial transactions to AI inference pipelines. However, in the domains of

Hugo Guerrero

Kong Insomnia 12.4: Better Tabs, Clearer Commits, Smarter Admin

Product ReleasesMarch 5, 2026

We've been all ears. Your workflows clearly told us what mattered most: tabs that adapt to how you actually work, Git commits you can actually understand, and admin controls that don't require a manual to navigate. Insomnia v12.4 discards the fricti

Haley Giuliano

Ready to see Kong in action?

Get a personalized walkthrough of Kong's platform tailored to your architecture, use cases, and scale requirements.

Get a Demo
Ask AI for a summary of Kong
Stay connected
    • Company
    • About Kong
    • Customers
    • Careers
    • Press
    • Events
    • Contact
    • Pricing
    • Legal
    • Terms
    • Privacy
    • Trust and Compliance
    • Platform
    • Kong AI Gateway
    • Kong Konnect
    • Kong Gateway
    • Kong Event Gateway
    • Kong Insomnia
    • Documentation
    • Book Demo
    • Compare
    • AI Gateway Alternatives
    • Kong vs Apigee
    • Kong vs IBM
    • Kong vs Postman
    • Kong vs Mulesoft
    • Explore More
    • Open Banking API Solutions
    • API Governance Solutions
    • Istio API Gateway Integration
    • Kubernetes API Management
    • API Gateway: Build vs Buy
    • Kong vs Apigee
    • Open Source
    • Kong Gateway
    • Kuma
    • Insomnia
    • Kong Community

Kong enables the connectivity layer for the agentic era – securely connecting, governing, and monetizing APIs and AI tokens across any model or cloud.

  • Japanese
  • Frenchcoming soon
  • Spanishcoming soon
  • Germancoming soon
© Kong Inc. 2026